Adding ability to set secure flag