Added security logic.