You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
42 lines
946 B
42 lines
946 B
#if !BESTHTTP_DISABLE_ALTERNATE_SSL && (!UNITY_WEBGL || UNITY_EDITOR) |
|
#pragma warning disable |
|
using System; |
|
using System.IO; |
|
|
|
namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Bcpg |
|
{ |
|
/// <remarks>Basic packet for an experimental packet.</remarks> |
|
public class ExperimentalPacket |
|
: ContainedPacket //, PublicKeyAlgorithmTag |
|
{ |
|
private readonly PacketTag tag; |
|
private readonly byte[] contents; |
|
|
|
internal ExperimentalPacket( |
|
PacketTag tag, |
|
BcpgInputStream bcpgIn) |
|
{ |
|
this.tag = tag; |
|
|
|
this.contents = bcpgIn.ReadAll(); |
|
} |
|
|
|
public PacketTag Tag |
|
{ |
|
get { return tag; } |
|
} |
|
|
|
public byte[] GetContents() |
|
{ |
|
return (byte[]) contents.Clone(); |
|
} |
|
|
|
public override void Encode( |
|
BcpgOutputStream bcpgOut) |
|
{ |
|
bcpgOut.WritePacket(tag, contents, true); |
|
} |
|
} |
|
} |
|
#pragma warning restore |
|
#endif
|
|
|