Completed draft security/core functionality