2016-09-06 11:16:38 +00:00
|
|
|
/**
|
2016-09-11 20:20:15 +00:00
|
|
|
* Author......: See docs/credits.txt
|
2016-09-06 11:16:38 +00:00
|
|
|
* License.....: MIT
|
|
|
|
*/
|
|
|
|
|
2023-01-17 19:25:40 +00:00
|
|
|
#ifndef TERMINAL_H
|
|
|
|
#define TERMINAL_H
|
2016-09-06 11:16:38 +00:00
|
|
|
|
|
|
|
#include <stdio.h>
|
2016-09-11 08:39:19 +00:00
|
|
|
#include <string.h>
|
2016-09-06 11:16:38 +00:00
|
|
|
#include <sys/time.h>
|
|
|
|
#include <sys/types.h>
|
|
|
|
#include <unistd.h>
|
|
|
|
|
2017-02-23 23:55:06 +00:00
|
|
|
#if defined (_WIN)
|
|
|
|
#include <windows.h>
|
|
|
|
#else
|
2016-09-06 11:16:38 +00:00
|
|
|
#include <termios.h>
|
2016-09-07 20:29:57 +00:00
|
|
|
#if defined (__APPLE__)
|
2016-09-06 20:25:54 +00:00
|
|
|
#include <sys/ioctl.h>
|
|
|
|
#endif // __APPLE__
|
2016-09-06 11:16:38 +00:00
|
|
|
#endif // _WIN
|
|
|
|
|
2022-01-29 07:15:28 +00:00
|
|
|
#if !defined (_WIN) && !defined (__CYGWIN__) && !defined (__MSYS__)
|
|
|
|
#include <sys/utsname.h>
|
|
|
|
#if !defined (__linux__)
|
|
|
|
#include <sys/sysctl.h>
|
|
|
|
#endif // ! __linux__
|
|
|
|
#endif // ! _WIN && | __CYGWIN__ && ! __MSYS__
|
|
|
|
|
2016-10-23 15:31:22 +00:00
|
|
|
void welcome_screen (hashcat_ctx_t *hashcat_ctx, const char *version_tag);
|
2017-12-10 00:40:45 +00:00
|
|
|
void goodbye_screen (hashcat_ctx_t *hashcat_ctx, const time_t proc_start, const time_t proc_stop);
|
2016-09-28 21:53:46 +00:00
|
|
|
|
2016-10-30 17:55:27 +00:00
|
|
|
int setup_console (void);
|
2016-09-28 21:40:16 +00:00
|
|
|
|
2017-11-26 09:50:22 +00:00
|
|
|
void send_prompt (hashcat_ctx_t *hashcat_ctx);
|
|
|
|
void clear_prompt (hashcat_ctx_t *hashcat_ctx);
|
2016-09-11 08:39:19 +00:00
|
|
|
|
2018-09-18 21:37:30 +00:00
|
|
|
HC_API_CALL void *thread_keypress (void *p);
|
2016-09-15 02:21:41 +00:00
|
|
|
|
2016-09-08 07:21:25 +00:00
|
|
|
#if defined (_WIN)
|
|
|
|
void SetConsoleWindowSize (const int x);
|
|
|
|
#endif
|
|
|
|
|
2022-03-31 17:19:16 +00:00
|
|
|
int tty_break (void);
|
|
|
|
int tty_getchar (void);
|
|
|
|
int tty_fix (void);
|
2016-09-06 16:44:05 +00:00
|
|
|
|
2022-03-31 17:19:16 +00:00
|
|
|
bool is_stdout_terminal (void);
|
2022-03-18 14:54:26 +00:00
|
|
|
|
2017-03-24 09:45:40 +00:00
|
|
|
void compress_terminal_line_length (char *out_buf, const size_t keep_from_beginning, const size_t keep_from_end);
|
|
|
|
|
2020-12-29 03:58:58 +00:00
|
|
|
void hash_info (hashcat_ctx_t *hashcat_ctx);
|
|
|
|
|
2019-05-01 13:52:56 +00:00
|
|
|
void backend_info (hashcat_ctx_t *hashcat_ctx);
|
|
|
|
void backend_info_compact (hashcat_ctx_t *hashcat_ctx);
|
2016-12-09 22:44:43 +00:00
|
|
|
|
|
|
|
void status_progress_machine_readable (hashcat_ctx_t *hashcat_ctx);
|
|
|
|
void status_progress (hashcat_ctx_t *hashcat_ctx);
|
|
|
|
void status_speed_machine_readable (hashcat_ctx_t *hashcat_ctx);
|
|
|
|
void status_speed (hashcat_ctx_t *hashcat_ctx);
|
|
|
|
void status_display_machine_readable (hashcat_ctx_t *hashcat_ctx);
|
|
|
|
void status_display (hashcat_ctx_t *hashcat_ctx);
|
|
|
|
void status_benchmark_machine_readable (hashcat_ctx_t *hashcat_ctx);
|
|
|
|
void status_benchmark (hashcat_ctx_t *hashcat_ctx);
|
2016-10-25 14:40:06 +00:00
|
|
|
|
2023-01-17 19:25:40 +00:00
|
|
|
#endif // TERMINAL_H
|