In this commit, we enhance the `GeneratePrivateKey` and `ParsePrivateKeyPEM` functions:
- Added validation for unsupported key types and provided a more descriptive error message.
This function supports ECDSA (using P-256) and RSA (with a key size of 3072 bits) algorithms.
It returns an error for unsupported key types.
- Improved error handling to include the type of the unsupported key format in the error message.
This function now provides more informative feedback when the private key format is neither RSA nor ECDSA.
Signed-off-by: Mohamed Awnallah <mohamedmohey2352@gmail.com>
In this commit, we fix th null pointer dereference issue
that happens in altnames mutators for both Karmada APIServer
and EtcdServer when accessing the `Components` field on
`AltNamesMutatorConfig` struct.
Signed-off-by: Mohamed Awnallah <mohamedmohey2352@gmail.com>