An enclosed chamber with a heavy airtight door on either side. One door leads to space or some other environment (poisonous or dense atmosphere, underwater, etc.), the other to the inside of a ship, vehicle, or habitat. An airlock allows people or objects to leave or enter the vessel without decompressing or flooding it. Airlocks have safety features that prevent both doors being opened at once. In some instances airlocks are replaced by airwalls.