Libraryless. Click here for Pure Java version (3153L/21K).
1 | static PKIKeyPair keyPairForProgram() {
|
2 | lock programLock(); |
3 | File f = secretProgramFile("key-pair.txt");
|
4 | pcall {
|
5 | PKIKeyPair pair = pkiKeyPairFromTwoLineFile(f); |
6 | if (pair != null) ret pair; |
7 | } |
8 | PKIKeyPair pair = pki_newKeyPair(); |
9 | saveTextFile(f, linesLL(pair.publicKey, pair.privateKey)); |
10 | ret pair; |
11 | } |
Began life as a copy of #1018438
download show line numbers debug dex old transpilations
Travelled to 6 computer(s): bhatertpkbcr, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tvejysmllsmz, vouqrxazstgt
No comments. add comment
| Snippet ID: | #1023672 |
| Snippet name: | keyPairForProgram - make/get a key pair for this program on this machine |
| Eternal ID of this version: | #1023672/6 |
| Text MD5: | e5d464c346543955e3818a0e21bb9e7c |
| Transpilation MD5: | fc3958579ca725cbb5dc9e48e722b786 |
| Author: | stefan |
| Category: | javax / pki |
| Type: | JavaX fragment (include) |
| Public (visible to everyone): | Yes |
| Archived (hidden from active list): | No |
| Created/modified: | 2019-07-03 14:01:58 |
| Source code size: | 328 bytes / 11 lines |
| Pitched / IR pitched: | No / No |
| Views / Downloads: | 619 / 722 |
| Version history: | 5 change(s) |
| Referenced in: | [show references] |