Sort of.

Extended version? there is a mathematical relationship between the two keys such that given the original constants and one of the keys, you can compute the other.

For RSA, that is such that for the three values M (modulus), E (encryption exponent) and D (decryption exponent) then cryptotext=plaintext to the power of E modulo M, and plaintext = cryptotext to the power of D modulo M. this is reversible, in that if you swap E and D over, the math still works.

however, for any pair (E,M) there are an infinite number of possible values for D, all with a rigid mathematical relationship to each other. You don't HAVE to pick the smallest one, but it usually makes sense to do so (as otherwise you are just doing more math for no real benefit)

Summary of RSA would go like this (and I have a t-shirt with this on someplace here :)

Pick two prime numbers P and Q

Your M is the value P x Q

now, pick an E (say, 512) and calculate N as the value (P - 1) x (Q - 1)

Now, any D such that E x D = 1 Mod N is suitable.

now, given you can write "Mod N" as "i x N" for some arbitrary integer i you can rearrange that so that for any given value i, you can calculate the resulting D value.

conversely, if you have calculated some D, you can go ahead and calculate other values of E by varying the value of i.

Does that make sense?

Extended version? there is a mathematical relationship between the two keys such that given the original constants and one of the keys, you can compute the other.

For RSA, that is such that for the three values M (modulus), E (encryption exponent) and D (decryption exponent) then cryptotext=plaintext to the power of E modulo M, and plaintext = cryptotext to the power of D modulo M. this is reversible, in that if you swap E and D over, the math still works.

however, for any pair (E,M) there are an infinite number of possible values for D, all with a rigid mathematical relationship to each other. You don't HAVE to pick the smallest one, but it usually makes sense to do so (as otherwise you are just doing more math for no real benefit)

Summary of RSA would go like this (and I have a t-shirt with this on someplace here :)

Pick two prime numbers P and Q

Your M is the value P x Q

now, pick an E (say, 512) and calculate N as the value (P - 1) x (Q - 1)

Now, any D such that E x D = 1 Mod N is suitable.

now, given you can write "Mod N" as "i x N" for some arbitrary integer i you can rearrange that so that for any given value i, you can calculate the resulting D value.

conversely, if you have calculated some D, you can go ahead and calculate other values of E by varying the value of i.

Does that make sense?