Package net.i2p.data

Class PrivateKeyFile

java.lang.Object
net.i2p.data.PrivateKeyFile
Direct Known Subclasses:
RouterPrivateKeyFile

public class PrivateKeyFile
extends Object
This helper class reads and writes files in the same "eepPriv.dat" format used by the client code. The format is:
  - Destination (387 bytes if no certificate, otherwise longer)
     - Public key (256 bytes)
     - Signing Public key (128 bytes)
     - Cert. type (1 byte)
     - Cert. length (2 bytes)
     - Certificate if length != 0
  - Private key (256 bytes)
  - Signing Private key (20 bytes, or length specified by key certificate)
  - As of 0.9.38, if the Signing Private Key is all zeros,
    the offline signature section (see proposal 123):
     - Expires timestamp (4 bytes, seconds since epoch, rolls over in 2106)
     - Sig type of transient public key (2 bytes)
     - Transient Signing Public key (length as specified by transient sig type)
     - Signature of Signed Public key by offline key (length as specified by destination sig type)
     - Transient Signing Private key (length as specified by transient sig type)

 Total: 663 or more bytes
Author:
welterde, zzz