44 static bool size_ok(
unsigned int sz,
unsigned int nelem ) ;
45 static bool pathname_ok(
const std::string &path,
bool strict ) ;
Functions to clean/scrub input for security reasons.
static bool size_ok(unsigned int sz, unsigned int nelem)
sanitize the size of an array. Test for integer overflow when dynamically allocating an array.
static bool pathname_ok(const std::string &path, bool strict)
Does the string name a potentailly valid pathname? Test the given pathname to verfiy that it is a val...
static bool command_line_arg_ok(const std::string &arg)
sanitize command line arguments