A method for identifying a device in a network comprising: detecting, from the network, a request directed at the device; identifying, from the request, a source entity that sent the request and a security level specified by the request; and determining, among a plurality keys that identify the device for different levels of security, one or more of the keys to identify the device according to at least the security level; and: in response to the security level being a high security level, establishing a network session with the high security level to communicate with the source entity using a set of inter-related keys among the plurality of keys to identify the device, wherein the set of inter-related keys include a main identity, a first alias of the main identity, and a second alias of the first alias of the main identity, wherein both of the first alias and the second alias are used in response to the security level being at a high security level; in response to the security level being at a lower level than the high security level, using the alias of the main identity as a key for establishing the network session; performing a select-and-mask operation on a bit pattern stored in the device to obtain a sub-pattern, wherein the select-and-mask operation specifies a beginning bit location in the bit pattern, an end bit location in the bit pattern, and the number of bits in the bit pattern to skip between successive bits of the sub-pattern; and using the sub-pattern as the main identity. detecting, from the network, a request directed at the device; identifying, from the request, a source entity that sent the request and a security level specified by the request; and determining, among a plurality keys that identify the device for different levels of security, one or more of the keys to identify the device according to at least the security level; and: in response to the security level being a high security level, establishing a network session with the high security level to communicate with the source entity using a set of inter-related keys among the plurality of keys to identify the device, wherein the set of inter-related keys include a main identity, a first alias of the main identity, and a second alias of the first alias of the main identity, wherein both of the first alias and the second alias are used in response to the security level being at a high security level; in response to the security level being at a lower level than the high security level, using the alias of the main identity as a key for establishing the network session; performing a select-and-mask operation on a bit pattern stored in the device to obtain a sub-pattern, wherein the select-and-mask operation specifies a beginning bit location in the bit pattern, an end bit location in the bit pattern, and the number of bits in the bit pattern to skip between successive bits of the sub-pattern; and using the sub-pattern as the main identity. in response to the security level being a high security level, establishing a network session with the high security level to communicate with the source entity using a set of inter-related keys among the plurality of keys to identify the device, wherein the set of inter-related keys include a main identity, a first alias of the main identity, and a second alias of the first alias of the main identity, wherein both of the first alias and the second alias are used in response to the security level being at a high security level; in response to the security level being at a lower level than the high security level, using the alias of the main identity as a key for establishing the network session; performing a select-and-mask operation on a bit pattern stored in the device to obtain a sub-pattern, wherein the select-and-mask operation specifies a beginning bit location in the bit pattern, an end bit location in the bit pattern, and the number of bits in the bit pattern to skip between successive bits of the sub-pattern; and using the sub-pattern as the main identity.