Easy use of the Ledger new SDK - Liquidateur

EthereumZuri.ch 2025 · 31 Jan 2025 · 14:12

Ledger device apps are presented as a defense against blind signing: they derive accounts, verify addresses and put transaction approval on a hardware display, though raw data may remain an unintelligible hash. The toolchain includes an open-source SDK, Speculos simulator, testing, a VS Code extension, boilerplates and an app repository. For Ethereum dapps, the proposed route is ERC-7730 mapping for simpler contracts or a custom plugin for specialized behavior; an unlabeled Q&A response explains that contract functions must be mapped into JSON for clear signing.

Speakers

Topics

From EthereumZuri.ch 2025, hosted by EthereumZuri.ch.

Transcript

hi [Applause] everyone Hi everyone uh so I'm acam de lger um so the title is a bit different uh I specified before The Ledger new SDK but the device up kit here is part of the new uh SDK we launched last year um so I will be talking uh with you about the device app um why it's important for security and how you can build your own uh device application uh on Ledger hard device so let's go um so if you already use a ler Hardware device uh who has a ler

Hardware device here okay half of the the crowd um so you already installed a device application on your Hardware device in order to interact with a specific chain um this device application has a really crucial role uh why the first one um the device application is responsible for to for deriving the seed so the device application will be will allow you to create multiple accounts on multiple chains from the seed uh on your Hardware device so this is one of the role another one it allows you to ver verify addresses to ensure that um it's correct it's not corrupted what you have

on the screen is the correct address and you can compare it to what you have on on on your computer for example another role also crucial um this is with a device application that you will sign transaction on a display we call it a trusted display and I will tell you later why we call it that way but this display will allow you to sign transactions and ensure that what you're signing what you're seeing on your device is uh what you're signing so as as I said we say once it to rule them all from uh a seed you can derive multiple accounts but depending

on the Chain you want you're working with the device application you will have specific uh make file and each uh device application uh will have its own derivation path so why do we say don't trust verify at Ledger the main reason reason is uh when you verify on your Hardware device as I said earlier um it will allow you to verify addresses before sharing it ensure that it's the correct thing that it's uh it appears and also because if you're only relying on software wallets you know that um addresses on software

wallet could be compromised and that's not the case uh on a trusted display on a ledger Hardware device let should take the picture so we also say what you see is what you sign why um on a hardware device on a liser hardware device you have a secure element chip that um secure your sensitive data and the display on the hardware device is directly linked to uh this secure element chip so it's kind of immune to hacks it allows you to trust directly the display so even if you have your computer on the side on your

Hardware device you can compare from your Hardware device to what you have on your computer and ensure that uh what you're signing is the correct thing and this is why we say what you see is what you see on your Hardware device is what you're going to say so having a display that you can trust is let's say the the first layer so you have your uh display you have the transaction that is displayed on your screen this is the first layer but often the transaction that appears is kind of hash uh uh many numbers LS that you don't necessarily understand and on top of the trusted display what we want to add and what we uh began to push also

many years ago but mainly also last year we began on etherum is what we call the Clear sign so here on the screen you have a transaction so you can agree with me that you can understand this transaction you know from which address you're sending uh the funds you know the amount you're sending you know to which address you're sending and you know the fees so this is allowed by what we call the Clear signing what we are trying to implement and push not only for us but for everyone a good practice uh in order to avoid what we call also blind signing and so why does it matter why clear signing for example trusted

display matters when you're only relying on software wallet you have not necessar guarantee that the data displayed on the on the wallet interface is what you're going to sign if you add this layer on top of it you will ensure that more security uh better behavior and that what you're assigning is what you're really signing not something else so building a device application who is it for some data before so on the uh The Ledger store we have more than 150

apps for different chains specific chains also for other kind of behaviors also more than 90% of them were built by thirdparty developers so not necessary Ledger and we have someone here that is building uh device applications for Ledger I know at the end of the room um and more that we secure more than 20% of the word crypto assets so having more and more device applications being able to interact with specific chains is really important not only for um you users but also for

security so how can you develop your own device application first of all uh we provide many tooling the first one uh we have an op open source SDK uh that is described also on our developer portal that will allow you to uh easily work on on this SDK we also have a simulator we call a speculas that will allow to simulate the operating system so the behavior of the hardware device with what you're trying to uh to build if you're building a device application sorry a test framework also an extension we launched on

uh I don't know when but long time ago on Visual Studio code that will uh help you accelerate uh your development of a device application and different border Place applications depending on the language you're coding on or if you're building a device application or a plug-in and on top of that we have also our repo where you can find all the device applications that are available on The Ledger store so you can have a look at it how it's built you can Fork it also uh work on it and also side load a device application a custom one directly on The Ledger Hardware device no picture sorry

so depend depending on uh what you are or for which company which project project work you will have different paths let's say your blockchain foundation uh on an NM chain or Cosmos or or Euro clone if um let's say you are targeting to have a device application that does a flow that is already supported by a device application on the store no need to build it you can leverage a device application that already uh exist if you need to do custom Behavior custom flow specific things this is when you need to uh build your own device

application now let's say that uh you're adap and adap on ethereum first option as a blockchain foundation you are looking for a a classic flow not too complicated the function functions of your smart contract is not too much complicated you can push a per push uh P request sorry on the ERC 7730 repo that will allow you to uh add your uh to map your smart contract to our repo and then allow you to uh have your dab clear signed and then users will be able to uh use the hardware device with your dab but let's say you have a dab that is a little more

complicated does specific things things specific behavior same thing at the the previous uh use case you will need to build your own plugin for that we call it a plugin uh for specific use case so we say that today it has never been so easy to develop a device app maybe I know will confirm yes no not always so as I said we provide uh many boiler Place let's say like that depending on the language you want to to build on if you're targeting a device application you need a device application you can leverage our boiler plate either in C or rest and if you

need a a plugin for your dab for example we have the same thing a border plate application plugin and the same only uh in C as I said earlier we also have um an extension on Visual Studio code that will allow you provide you also more tuning help you to to accelerate your development of your device application and that's it so everything I said is described on our developer portal um same thing as I said at the beginning all the device applications are listed on our leder GitHub repo you have all the device application ethereum

Bitcoin everything on this repo and later in in the future if you have some questions you can reach out to us directly uh on our Discord server sorry and normally that should be another page um because they added a poop uh C code so yeah perfect thank you so uh we are doing also ruffle if you uh scan this cure code and might the the pup you might uh let's say win uh sorry I need the water a ledger Hardware device so it

will be Ledger Nanos plus like this one so we have some uh in a room and later today at 5:00 pm on the main on I think it will be on the main stage we will announce people who want the leder hardware device so feel free to to me it and uh yeah maybe we'll have one later today uh thank you very much I think I'm I'm done um if you have any questions let me know or you can I will be uh all day here at the conference yeah go ahead so uh maybe uh for Clear sign

if at all it's a ethereum transaction it's okay you can decode but for example if you have a smart contract interaction uh you need to know the ABI of the code like you need to know how to decode the and display on the clear signing right so yeah so if at all uh there is no verified contracts how do you guys deal with this and uh how do you display this okay so you will have to take your smart contract list the function used on your smart contract and sorry on our side we will have a Json file and you will have to map all your function into uh uh there is a format for the Json file describing each

of your functions on this Json file and this this file will be able to traduce the behavior of your smart contract and then clear sign for the users any other questions yep question oh who uh it worked for you okay okay so it's working perfect so yeah at 5:00 P PM later today um we'll

announce the people who won The Ledger Hardware device so thank you uh thank you very much thank you Mercy Liquidator so we are here at 10:55 with the next talk [Music]