1. An integrated circuit comprising: a controller; multiple internal circuitries; an internal key comparison device; and a security mode determination device that comprises multiple one time programmable components for defining a security mode out of multiple possible security modes, whereas the selected security mode affects access to the internal circuitries and the multiple possible security modes include a first security mode to deny access to certain internal circuitry, a second security mode to initiate a key based security sequence, a third security mode to allow testing functionality, a fourth security mode to allow access even to secure components, wherein the first security mode, the second security mode, the third security mode, and the fourth security mode are different from each other; whereas the controller and the security mode determination unit are responsive to an output of a reset determination unit, and wherein the controller requires a user to reset the integrated circuit in response to an external debug device requests a switch from the selected security mode to a less secure security mode, and wherein the controller is adapted to apply multiple key base security modes.