base/asm-common.h: Add register-name conversions for ARM64 registers.
[catacomb] / symm / des.h
index 682be6b..6f5ebbe 100644 (file)
@@ -66,6 +66,23 @@ typedef struct des_ctx {
 
 /*----- Functions provided ------------------------------------------------*/
 
+/* --- @des_fixparity@ --- *
+ *
+ * Arguments:  @octet *z@ = output buffer pointer, or null
+ *             @const octet *p@ = input buffer pointer
+ *             @size_t sz@ = size of the buffers
+ *
+ * Returns:    Zero if the input already had correct parity, @-1@ if changes
+ *             were necessary (in constant time).
+ *
+ * Use:                Check the @sz@ bytes at @p@ for odd parity (as used in DES
+ *             keys); if @z@ is not null, then copy a parity-fixed version
+ *             of @p@ to @z@.  The two buffers at @p@ and @z@ may coincide,
+ *             or be disjoint, but not otherwise overlap.
+ */
+
+extern int des_fixparity(octet */*z*/, const octet */*p*/, size_t /*sz*/);
+
 /* --- @des_expand@ --- *
  *
  * Arguments:  @const octet *k@ = pointer to key material