File: crypto_verify_bytes.h

package info (click to toggle)
python-scrypt 0.9.4-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 832 kB
  • sloc: ansic: 6,290; python: 733; sh: 99; makefile: 5
file content (14 lines) | stat: -rw-r--r-- 413 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
#ifndef CRYPTO_VERIFY_BYTES_H_
#define CRYPTO_VERIFY_BYTES_H_

#include <stddef.h>
#include <stdint.h>

/**
 * crypto_verify_bytes(buf0, buf1, len):
 * Return zero if and only if ${buf0[0 .. len - 1]} and ${buf1[0 .. len - 1]}
 * are identical.  Do not leak any information via timing side channels.
 */
uint8_t crypto_verify_bytes(const uint8_t *, const uint8_t *, size_t);

#endif /* !CRYPTO_VERIFY_BYTES_H_ */