Fix secure check