DUKPTCore
A .NET Standard implementation of TDES DUKPT, both PIN and Data variants.
Install / Use
/learn @rbonestell/DUKPTCoreREADME
DUKPTCore

A .NET Standard implementation of TDES DUKPT, both PIN and Data variants.
About DUKPTCore
You'll find this library useful if you're working on financial services applications with the need to decrypt data using TDES (3DES, TDEA, triple-DES, etc) DUKPT (derived unique key per transaction), such as PIN or credit card account data.
DUKPTCore was adapted from sgbj's Dukpt.NET project and ported to .NET Standard.
Examples
Encrypting data:
string bdk = "0123456789ABCDEFFEDCBA9876543210";
string ksn = "FFFF9876543210E00008";
byte[] superSecretMessage = Encoding.UTF8.GetBytes("Hello World!");
byte[] encryptedData = DUKPT.Encrypt(bdk, ksn, superSecretMessage, DUKPTVariant.Data);
Decrypting data:
byte[] decryptedData = DUKPT.Decrypt(bdk, ksn, encryptedData, DUKPTVariant.Data);
string superSecretMessage = Encoding.UTF8.GetString(decryptedData); // Hello World!
Resources
- ANSI X9.24 - Retail Financial Services Set
- How To Decrypt Credit Card Data, Part I - IDTECH
- How To Decrypt Credit Card Data, Part II - IDTECH
- How To Decrypt Magnetic Card Data With DUKPT - Parthenon Software Group, Travis Hoffman
- Dukpt.NET - Scott Batary (sgbj)
- Derived unique key per transaction - Wikipedia
Contributing
- Fork it!
- Create your feature branch:
git checkout -b my-new-feature - Commit your changes:
git commit -am 'Added some new feature' - Push to the branch:
git push origin my-new-feature - Submit a pull request!
Related Skills
node-connect
347.2kDiagnose OpenClaw node connection and pairing failures for Android, iOS, and macOS companion apps
frontend-design
108.0kCreate distinctive, production-grade frontend interfaces with high design quality. Use this skill when the user asks to build web components, pages, or applications. Generates creative, polished code that avoids generic AI aesthetics.
openai-whisper-api
347.2kTranscribe audio via OpenAI Audio Transcriptions API (Whisper).
qqbot-media
347.2kQQBot 富媒体收发能力。使用 <qqmedia> 标签,系统根据文件扩展名自动识别类型(图片/语音/视频/文件)。
