Use Minecart Mania - It has a feature like this. I think you put [Lock] on a sign then [Unlock] but I am not sure - you should take a look at the wiki for it. http://wiki.afforess.com/Minecart_Mania-Plugin/Sign_Commands#Lock_Sign