Use the password changer on the second door and change its password. (Fair warning: The password won't save, if you reload your world, so never lock the door afterwards, unless you have the password changer on hand.)