◆ GetByteSize()
uint binlex::Common::GetByteSize |
( |
string |
s | ) |
|
This method gets the size in bytes of a trait string (includes wildcards).
- Parameters
-
- Returns
- Returns uint size of bytes
◆ Hexdump()
void binlex::Common::Hexdump |
( |
const char * |
desc, |
|
|
const void * |
addr, |
|
|
const int |
len |
|
) |
| |
This method prints hexdump to stdout.
- Parameters
-
desc | A description of the data. |
data | A pointer to the data |
size | The size of the data to collect |
◆ HexdumpBE()
string binlex::Common::HexdumpBE |
( |
const void * |
data, |
|
|
size_t |
size |
|
) |
| |
This method creates a byte string based on a pointer and its size.
- Parameters
-
data | A pointer to the data |
size | The size of the data to collect |
- Returns
- Returns a byte string of the selected data
◆ RemoveSpaces()
string binlex::Common::RemoveSpaces |
( |
string |
s | ) |
|
This method removes spaces from a string.
- Parameters
-
- Returns
- Returns string without spaces
◆ RemoveWildcards()
string binlex::Common::RemoveWildcards |
( |
string |
trait | ) |
|
This method removes wildcards from a trait string.
- Parameters
-
- Returns
- Returns trait without wildcards
◆ SHA256()
string binlex::Common::SHA256 |
( |
const char * |
trait | ) |
|
This class contains methods common to binlex. This method takes an input string and returns its sha256 hash.
- Parameters
-
- Returns
- Returns the sha256 hash of the trait string
◆ TraitToChar()
vector<char> binlex::Common::TraitToChar |
( |
string |
trait | ) |
|
This method takes an input trait string and returns a char vector of bytes (ignores wildcards).
- Parameters
-
- Returns
- Returns char vector of bytes
◆ TrimRight()
string binlex::Common::TrimRight |
( |
const std::string & |
s | ) |
|
This method removes whitespace on the right.
- Parameters
-
- Returns
- Returns string with whitespace on right trimmed
◆ WildcardTrait()
string binlex::Common::WildcardTrait |
( |
string |
trait, |
|
|
string |
bytes |
|
) |
| |
This method wildcards byte strings for traits.
- Parameters
-
trait | input trait string |
bytes | byte string to wildcard |
- Returns
- Returns wildcarded trait string
The documentation for this class was generated from the following file: