Enabled anti direct access and refresh function

For mailing