added stuff to security.cpp