-/* $OpenBSD: dsa.h,v 1.26 2018/02/18 14:58:12 tb Exp $ */
+/* $OpenBSD: dsa.h,v 1.27 2018/02/20 17:45:44 tb Exp $ */
/* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com)
* All rights reserved.
*
int DSA_set0_pqg(DSA *d, BIGNUM *p, BIGNUM *q, BIGNUM *g);
void DSA_get0_key(const DSA *d, const BIGNUM **pub_key, const BIGNUM **priv_key);
int DSA_set0_key(DSA *d, BIGNUM *pub_key, BIGNUM *priv_key);
+void DSA_clear_flags(DSA *d, int flags);
+int DSA_test_flags(const DSA *d, int flags);
+void DSA_set_flags(DSA *d, int flags);
#define EVP_PKEY_CTX_set_dsa_paramgen_bits(ctx, nbits) \
EVP_PKEY_CTX_ctrl(ctx, EVP_PKEY_DSA, EVP_PKEY_OP_PARAMGEN, \
-/* $OpenBSD: dsa_lib.c,v 1.26 2018/02/18 14:58:12 tb Exp $ */
+/* $OpenBSD: dsa_lib.c,v 1.27 2018/02/20 17:45:44 tb Exp $ */
/* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com)
* All rights reserved.
*
return 1;
}
+
+void
+DSA_clear_flags(DSA *d, int flags)
+{
+ d->flags &= ~flags;
+}
+
+int
+DSA_test_flags(const DSA *d, int flags)
+{
+ return d->flags & flags;
+}
+
+void
+DSA_set_flags(DSA *d, int flags)
+{
+ d->flags |= flags;
+}