diff options
| author | inoguchi <> | 2020-03-10 11:10:53 +0000 | 
|---|---|---|
| committer | inoguchi <> | 2020-03-10 11:10:53 +0000 | 
| commit | 9feddb8f718ed9f6bea887f11ed40e629a8d07e8 (patch) | |
| tree | f6613cfabf9c3b22ea88adafc3e0eef8dc13fe05 /src/lib/libc/crypt/bcrypt.c | |
| parent | f06e55459ad96981abf401d5ccbb700ef0618af8 (diff) | |
| download | openbsd-9feddb8f718ed9f6bea887f11ed40e629a8d07e8.tar.gz openbsd-9feddb8f718ed9f6bea887f11ed40e629a8d07e8.tar.bz2 openbsd-9feddb8f718ed9f6bea887f11ed40e629a8d07e8.zip | |
Modify regress base64test.c
- Don't remove multi line CR/LF from bt->out when NL mode
  base64_encoding_test removes CR/LF from bt->out to compare with the encoding
  result. This is fine with NO NL mode, but it goes wrong with NL mode if
  encoding result is larger than 64 and multi line, like below.
  "eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4\neHh4eHh4eHh4eHh4\n"
- Use memcpy instead of asprintf to avoid lost '\0' at the end of data
  This test data loses trailing '\0' if using asprintf.
  "\x61\x47\x56\x73\x62\x47\x38\x3d\x0a\x00"
- Print original data if decoding result comparison fails
  This change is not for importing test data, but I just notice.
  It prints bt->out if fail to memcmp bt->in with decoding result.
ok bcook@ tb@
Diffstat (limited to 'src/lib/libc/crypt/bcrypt.c')
0 files changed, 0 insertions, 0 deletions
