Some of the basic defenses of a fortified dwelling: murder hole (hot sand works great!), rough and tumble stairs (stairs of varying widths and heights that ascend circling clockwise giving the descending swordsman the right had advantage), archers.

“Keep it under your hat” comes from the archer habit of keeping an extra bow string under his hat.