Improved key management is provided by a public key replacement apparatus
and method for operating over insecure networks. An active public key and
the mask of a replacement public key are provided by a key server to nodes
where the active key is used to encrypt and verify messages. To replace
the active public key with the replacement public key, a key replacement
message is sent to the node. The key replacement message contains the
replacement public key and contains the mask of the next replacement key.
The mask of the replacement public key may be generated by hashing or
encrypting. The key replacement message is signed by the active public key
and the replacement public key. Nodes are implemented by a computer, a
smart card, a stored data card in combination with a publicly accessible
node machine, or other apparatus for sending and/or receiving messages. In
a particular application, a financial transaction network, nodes are
consumer nodes, merchant nodes, or both, and transactions are securely
sent over a possible insecure network