How ciphertext was generated in card reader using DUKPT encryption?

后端 未结 4 823
眼角桃花
眼角桃花 2021-02-02 03:17

For

`BDK = \"0123456789ABCDEFFEDCBA9876543210\"` `KSN = \"FFFF9876543210E00008\"` 

The ciphertext generated was below

\"C25C1D         


        
4条回答
  •  予麋鹿
    予麋鹿 (楼主)
    2021-02-02 03:29

    Look at this: https://github.com/sgbj/Dukpt.NET, I was in a similar situation where i wondered how to implement dukpt on the terminal when the terminal has its own function calls which take the INIT and KSN to create the first key, so my only problem was to make sure the INIT key was generated the same way on the terminal as it is in the above mentioned repo's code, which was simple enough using ossl encryption library for 3des with ebc and applying the appropriate masks.

提交回复
热议问题