/** * Return the byte encoding of the signature section. * @return uninterpreted signature bytes. */ public byte[] GetSignatureBytes() { if (signatureEncoding != null) { return((byte[])signatureEncoding.Clone()); } MemoryStream bOut = new MemoryStream(); BcpgOutputStream bcOut = new BcpgOutputStream(bOut); foreach (MPInteger sigObj in signature) { try { bcOut.WriteObject(sigObj); } catch (IOException e) { throw new Exception("internal error: " + e); } } return(bOut.ToArray()); }
public abstract void Encode(BcpgOutputStream bcpgOut);
public override void Encode( BcpgOutputStream bcpgOut) { bcpgOut.WriteObjects(p, q, g, y); }
public override void Encode( BcpgOutputStream bcpgOut) { bcpgOut.WriteObject(x); }
public override void Encode( BcpgOutputStream bcpgOut) { bcpgOut.WritePacket(PacketTag.SecretKey, GetEncodedContents(), true); }
public override void Encode( BcpgOutputStream bcpgOut) { bcpgOut.WritePacket(PacketTag.Marker, marker, true); }
public override void Encode( BcpgOutputStream bcpgOut) { bcpgOut.WritePacket(tag, contents, true); }
public override void Encode( BcpgOutputStream bcpgOut) { bcpgOut.WritePacket(PacketTag.Trust, levelAndTrustAmount, true); }
public override void Encode( BcpgOutputStream bcpgOut) { bcpgOut.WriteShort((short)val.BitLength); bcpgOut.Write(val.ToByteArrayUnsigned()); }
public override void Encode( BcpgOutputStream bcpgOut) { bcpgOut.WritePacket(PacketTag.UserId, idData, true); }
public override void Encode( BcpgOutputStream bcpgOut) { bcpgOut.WritePacket(PacketTag.ModificationDetectionCode, digest, false); }