Added common functions

Signed-off-by: Byron Sanchez <byron@hackbytes.com>