Added permission-denied code

Checks attempt against current position, allows through if OK.