MCPcopy Create free account
hub / github.com/NetSPI/BOF-PE / ReadFileData

Function ReadFileData

common/standalone.cpp:84–94  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

82}
83
84static ByteArray ReadFileData(const std::string& file) {
85
86 std::ifstream infile(file, std::ios::binary);
87
88 infile.seekg(0, std::ios::end);
89 size_t length = infile.tellg();
90 infile.seekg(0, std::ios::beg);
91 ByteArray buffer(length);
92 infile.read(&buffer[0], length);
93 return std::move(buffer);
94}
95
96int GetPackedArguments(int argc, const char* argv[], const char* bof_args_def, std::string& result){
97

Callers 1

GetPackedArgumentsFunction · 0.85

Calls 1

readMethod · 0.45

Tested by

no test coverage detected