X-Git-Url: https://jxself.org/git/?a=blobdiff_plain;f=tfcrypt.h;h=a313b33d142fe8b5629f669aa4161acc0d0b2110;hb=0303cbcec2b262cc3dcf8d89951967d7ba9543c7;hp=acb1c420a112f55f3fe271f7b9c3328cdbea0f5e;hpb=d2e7d8aede7d69caffd59e4b0fa60e0c4b245201;p=tfcrypt.git diff --git a/tfcrypt.h b/tfcrypt.h index acb1c42..a313b33 100644 --- a/tfcrypt.h +++ b/tfcrypt.h @@ -2,7 +2,7 @@ * tfcrypt -- high security Threefish encryption tool. * * tfcrypt is copyrighted: - * Copyright (C) 2012-2018 Andrey Rys. All rights reserved. + * Copyright (C) 2012-2019 Andrey Rys. All rights reserved. * * tfcrypt is licensed to you under the terms of std. MIT/X11 license: * @@ -138,7 +138,7 @@ extern tfc_byte srcblk[TFC_BLKSIZE], dstblk[TFC_BLKSIZE], *pblk; extern tfc_byte macvrfy[SKEIN_DIGEST_SIZE], macresult[SKEIN_DIGEST_SIZE]; extern tfc_byte tmpdata[TFC_TMPSIZE]; extern char *randsource; -extern tfc_fsize iseek_blocks, iseek, oseek, maxlen; +extern tfc_fsize iseek_blocks, iseek, oseek, maxlen, ftrunc_dfd; extern tfc_fsize total_processed_src, total_processed_dst; extern tfc_fsize delta_processed; extern tfc_fsize genrandom_nr_bytes, genzero_nr_bytes; @@ -157,12 +157,12 @@ extern int counter_opt, mackey_opt, do_mac, do_outfmt, rawkey; extern int idx, write_flags; extern tfc_yesno catch_all_errors, ignore_seek_errors, password, overwrite_source, do_fsync, do_pad; extern tfc_yesno do_preserve_time, do_stats_in_gibs, do_statline_dynamic, do_less_stats; -extern tfc_yesno no_repeat, do_full_hexdump, verbose, statline_was_shown; +extern tfc_yesno no_repeat, do_full_hexdump, verbose, statline_was_shown, show_secrets; extern char *srcfname, *dstfname, *do_mac_file, *counter_file, *sksum_hashlist_file; extern char *saltf, *genkeyf, *mackeyf, *tweakf; extern char *pw_prompt, *mac_pw_prompt; extern tfc_useconds status_timer, bench_timer; -extern tfc_useconds current_time, delta_time; +extern tfc_useconds total_time, current_time, delta_time; extern struct getpasswd_state getps; size_t xread(int fd, void *data, size_t szdata); @@ -188,6 +188,7 @@ tfc_yesno str_empty(const char *str); void xclose(int fd); const char *tfc_modename(int mode); void tfc_getcurtime(tfc_useconds *tx); +char *tfc_format_time(tfc_useconds t); tfc_fsize tfc_fdsize(int fd); tfc_fsize tfc_fdgetpos(int fd); tfc_fsize tfc_fnamesize(char *fname, tfc_yesno noexit); @@ -207,6 +208,7 @@ void skein(void *hash, size_t bits, const void *key, const void *data, size_t sz tfc_yesno skeinfd(void *hash, size_t bits, const void *key, int fd, tfc_fsize offset, tfc_fsize readto); void read_defaults(const char *path, tfc_yesno noerr); +void hash_defaults(char *uhash, size_t szuhash); void gen_write_bytes(const char *foutname, tfc_fsize offset, tfc_fsize nrbytes); void do_edbase64(char **fargv); @@ -226,6 +228,6 @@ enum { TFC_MODE_SKSUM = -2, TFC_MODE_PLAIN = -1, TFC_MODE_CTR = 1, TFC_MODE_STREAM, TFC_MODE_XTS, TFC_MODE_ECB, TFC_MODE_CBC, TFC_MODE_OCB }; -enum { TFC_CTR_SHOW = 1, TFC_CTR_HEAD, TFC_CTR_RAND, TFC_CTR_ZERO }; +enum { TFC_CTR_SHOW = 1, TFC_CTR_HEAD, TFC_CTR_RAND, TFC_CTR_ZERO, TFC_CTR_SSET }; #endif