I'm using php OpenSSL in my project. How can I create multiple public keys using a single private key?
In RSA we can't do such things. But how about ECC?
By definition, for each private scalar (private key) in general elliptic curve crypto-systems, there is a single point on the curve (public key) generated by [k]G
where G
is the curves generator point and k
is the private scalar.
FYI, in a somewhat unusual quirk of birationally equivalent curves, you can actually map a Montgomery curve X25519 public key to two twisted Edwards curve Ed25519 public keys, as the Montgomery curve point does not carry a v coordinate, however, this will not help with your use-case.
Generally if we want to define multiple key pairs (not just public keys) from a single seed (source), one may do so using key derivation from a master key.
However, then you must take care of multiple private keys.
You seem to suggest the private key will live on the server, so I don't think you actually need multiple public keys. I suggest you use a single key pair and EdDSA or ECDSA to sign multiple key pairs for use on client devices. Signature can be used to link their source to a single identity.
Pls provide more context and I will help further.