diff options
Diffstat (limited to 'crypto/src/asn1/DerUniversalString.cs')
-rw-r--r-- | crypto/src/asn1/DerUniversalString.cs | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/crypto/src/asn1/DerUniversalString.cs b/crypto/src/asn1/DerUniversalString.cs index 29dbbce95..2e9baa76e 100644 --- a/crypto/src/asn1/DerUniversalString.cs +++ b/crypto/src/asn1/DerUniversalString.cs @@ -86,7 +86,12 @@ namespace Org.BouncyCastle.Asn1 return (byte[]) str.Clone(); } - internal override void Encode(Asn1OutputStream asn1Out, bool withID) + internal override int EncodedLength(bool withID) + { + return Asn1OutputStream.GetLengthOfEncodingDL(withID, this.str.Length); + } + + internal override void Encode(Asn1OutputStream asn1Out, bool withID) { asn1Out.WriteEncodingDL(withID, Asn1Tags.UniversalString, this.str); } |