HollowsHunter
Scans all running processes. Recognizes and dumps a variety of potentially malicious implants (replaced/implanted PEs, shellcodes, hooks, in-memory patches).
Loading...
Searching...
No Matches
term_util.h File Reference
#include <iostream>
#include <windows.h>
#include <mutex>

Go to the source code of this file.

Macros

#define BLACK   0
 
#define DARK_BLUE   1
 
#define DARK_GREEN   2
 
#define DARK_CYAN   3
 
#define DARK_RED   4
 
#define DARK_MAGENTA   5
 
#define BROWN   6
 
#define SILVER   7
 
#define GRAY   8
 
#define BLUE   9
 
#define LIME   0xA
 
#define CYAN   0xB
 
#define RED   0xC
 
#define MAGENTA   0xD
 
#define YELLOW   0xE
 
#define WHITE   0xF
 
#define MAKE_COLOR(fg_color, bg_color)
 
#define GET_BG_COLOR(color)
 
#define YELLOW_ON_BLACK   MAKE_COLOR(YELLOW, BLACK)
 
#define RED_ON_BLACK   MAKE_COLOR(RED, BLACK)
 

Functions

bool get_current_color (int descriptor, WORD &color)
 
WORD set_color (WORD color)
 
void print_in_color (WORD color, const std::string &text)
 

Variables

std::mutex g_stdOutMutex
 

Macro Definition Documentation

◆ BLACK

#define BLACK   0

Definition at line 9 of file term_util.h.

◆ BLUE

#define BLUE   9

Definition at line 18 of file term_util.h.

◆ BROWN

#define BROWN   6

Definition at line 15 of file term_util.h.

◆ CYAN

#define CYAN   0xB

Definition at line 20 of file term_util.h.

◆ DARK_BLUE

#define DARK_BLUE   1

Definition at line 10 of file term_util.h.

◆ DARK_CYAN

#define DARK_CYAN   3

Definition at line 12 of file term_util.h.

◆ DARK_GREEN

#define DARK_GREEN   2

Definition at line 11 of file term_util.h.

◆ DARK_MAGENTA

#define DARK_MAGENTA   5

Definition at line 14 of file term_util.h.

◆ DARK_RED

#define DARK_RED   4

Definition at line 13 of file term_util.h.

◆ GET_BG_COLOR

#define GET_BG_COLOR ( color)
Value:
(color >> 4)

Definition at line 27 of file term_util.h.

◆ GRAY

#define GRAY   8

Definition at line 17 of file term_util.h.

◆ LIME

#define LIME   0xA

Definition at line 19 of file term_util.h.

◆ MAGENTA

#define MAGENTA   0xD

Definition at line 22 of file term_util.h.

◆ MAKE_COLOR

#define MAKE_COLOR ( fg_color,
bg_color )
Value:
(fg_color | (bg_color << 4))

Definition at line 26 of file term_util.h.

◆ RED

#define RED   0xC

Definition at line 21 of file term_util.h.

◆ RED_ON_BLACK

#define RED_ON_BLACK   MAKE_COLOR(RED, BLACK)

Definition at line 30 of file term_util.h.

◆ SILVER

#define SILVER   7

Definition at line 16 of file term_util.h.

◆ WHITE

#define WHITE   0xF

Definition at line 24 of file term_util.h.

◆ YELLOW

#define YELLOW   0xE

Definition at line 23 of file term_util.h.

◆ YELLOW_ON_BLACK

#define YELLOW_ON_BLACK   MAKE_COLOR(YELLOW, BLACK)

Definition at line 29 of file term_util.h.

Function Documentation

◆ get_current_color()

bool get_current_color ( int descriptor,
WORD & color )

Definition at line 11 of file term_util.cpp.

◆ print_in_color()

void print_in_color ( WORD color,
const std::string & text )

Definition at line 33 of file term_util.cpp.

Here is the call graph for this function:

◆ set_color()

WORD set_color ( WORD color)

Definition at line 20 of file term_util.cpp.

Here is the call graph for this function:

Variable Documentation

◆ g_stdOutMutex

std::mutex g_stdOutMutex
extern

Definition at line 9 of file term_util.cpp.