The word "booby" may be an extension of the Spanish term bobo or bubie meaning dunce, or it may refer to seabirds (boobies) that are clumsy on land. In either case the term "booby trap" would indicate that it is intended to affect someone who is either foolish, unwary, or ill-prepared.
The earliest "booby traps" were simple pranks and tricks. Only later was the term applied to deadly improvisations during wartime, such as pits, snares, trip wires, or explosive traps.