From 378482f5a877e34ae9cabade06d6f3111c088f49 Mon Sep 17 00:00:00 2001 From: Peter Dettman Date: Thu, 14 Oct 2021 22:49:24 +0700 Subject: Initial pass at EncodedLength methods --- crypto/src/asn1/DerT61String.cs | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'crypto/src/asn1/DerT61String.cs') diff --git a/crypto/src/asn1/DerT61String.cs b/crypto/src/asn1/DerT61String.cs index e4f84b10a..82a8b3a43 100644 --- a/crypto/src/asn1/DerT61String.cs +++ b/crypto/src/asn1/DerT61String.cs @@ -77,6 +77,11 @@ namespace Org.BouncyCastle.Asn1 return str; } + internal override int EncodedLength(bool withID) + { + return Asn1OutputStream.GetLengthOfEncodingDL(withID, str.Length); + } + internal override void Encode(Asn1OutputStream asn1Out, bool withID) { asn1Out.WriteEncodingDL(withID, Asn1Tags.T61String, GetOctets()); -- cgit 1.4.1