Skip to content

Commit 04eeeec

Browse files
penguin42berrange
authored andcommitted
crypto: Remove unused DER string functions
qcrypto_der_encode_octet_str_begin and _end have been unused since they were added in 3b34cca ("crypto: Support DER encodings") Remove them. Signed-off-by: Dr. David Alan Gilbert <[email protected]> Reviewed-by: Daniel P. Berrangé <[email protected]> Signed-off-by: Daniel P. Berrangé <[email protected]>
1 parent cc5adbb commit 04eeeec

File tree

2 files changed

+0
-35
lines changed

2 files changed

+0
-35
lines changed

crypto/der.c

Lines changed: 0 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -408,19 +408,6 @@ void qcrypto_der_encode_octet_str(QCryptoEncodeContext *ctx,
408408
qcrypto_der_encode_prim(ctx, tag, src, src_len);
409409
}
410410

411-
void qcrypto_der_encode_octet_str_begin(QCryptoEncodeContext *ctx)
412-
{
413-
uint8_t tag = QCRYPTO_DER_TAG(QCRYPTO_DER_TAG_CLASS_UNIV,
414-
QCRYPTO_DER_TAG_ENC_PRIM,
415-
QCRYPTO_DER_TYPE_TAG_OCT_STR);
416-
qcrypto_der_encode_cons_begin(ctx, tag);
417-
}
418-
419-
void qcrypto_der_encode_octet_str_end(QCryptoEncodeContext *ctx)
420-
{
421-
qcrypto_der_encode_cons_end(ctx);
422-
}
423-
424411
size_t qcrypto_der_encode_ctx_buffer_len(QCryptoEncodeContext *ctx)
425412
{
426413
return ctx->root.dlen;

crypto/der.h

Lines changed: 0 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -242,28 +242,6 @@ void qcrypto_der_encode_null(QCryptoEncodeContext *ctx);
242242
void qcrypto_der_encode_octet_str(QCryptoEncodeContext *ctx,
243243
const uint8_t *src, size_t src_len);
244244

245-
/**
246-
* qcrypto_der_encode_octet_str_begin:
247-
* @ctx: the encode context.
248-
*
249-
* Start encoding a octet string, All fields between
250-
* qcrypto_der_encode_octet_str_begin and qcrypto_der_encode_octet_str_end
251-
* are encoded as an octet string. This is useful when we need to encode a
252-
* encoded SEQUENCE as OCTET STRING.
253-
*/
254-
void qcrypto_der_encode_octet_str_begin(QCryptoEncodeContext *ctx);
255-
256-
/**
257-
* qcrypto_der_encode_octet_str_end:
258-
* @ctx: the encode context.
259-
*
260-
* Finish encoding a octet string, All fields between
261-
* qcrypto_der_encode_octet_str_begin and qcrypto_der_encode_octet_str_end
262-
* are encoded as an octet string. This is useful when we need to encode a
263-
* encoded SEQUENCE as OCTET STRING.
264-
*/
265-
void qcrypto_der_encode_octet_str_end(QCryptoEncodeContext *ctx);
266-
267245
/**
268246
* qcrypto_der_encode_ctx_buffer_len:
269247
* @ctx: the encode context.

0 commit comments

Comments
 (0)