The gatehouse was probably one of the best defence that castles had. However, there were different ways to get through. In fact, one time at the Pontefract Castle attackers got through by pretending to be bed collectors. The reason the gatehouse was invented was because before attackers could get in and out whenever they wanted, and they could only make giant wood doors. The gate house had doors, drawbridges, and gates that had all sorts of surprises. There were holes that archers could shoot though, they also had bigger holes to pour boiling water through.
The moat and drawbridge where amazing things. You probably know about the moat but I bet you didn’t know that