Magic Lock

Magic Lock iis exactly what it says.

Spell Description
Sometimes, a mage doesn't want anyone to go through a specific door or loot a chest. Magic Lock magically locks them, and only the Unlock Magic spell can break the enchantment.

Trivia

 * In Ultima VI, if the Avatar uses Magic Lock on a already locked door, and then casts Unlock Magic, all locks, even the natural ones, are removed and the door can be opened.
 * In Ultima Underworld, the Strengthen Door spell is used to prevent entry.