Skip site navigation (1)Skip section navigation (2)

FreeBSD Manual Pages

  
 
  

home | help
byte_equal(3)		   Library Functions Manual		 byte_equal(3)

NAME
       byte_equal - compare two	strings

SYNTAX
       #include	<libowfat/byte.h>

       int byte_equal(const char *one,size_t len,const char *two);

DESCRIPTION
       byte_equal returns 1 if the strings are equal, 0	otherwise.

       When the	strings	are different, byte_equal does not read	bytes past the
       first  difference.  An attacker observing the execution timing can thus
       learn where the first mismatch happened.

       Use byte_equal_notimingattack to	compare	keys, passphrases, cookies  or
       hashes instead.

SEE ALSO
       byte_diff(3), byte_equal_notimingattack(3)

								 byte_equal(3)

Want to link to this manual page? Use this URL:
<https://man.freebsd.org/cgi/man.cgi?query=libowfat_byte_equal&sektion=3&manpath=FreeBSD+Ports+14.3.quarterly>

home | help