[ad_1]
Sort answer is “no”.
Long answer is to use sunrsasign Provider, which implements RSAKeyPairGenerator such that the public exponent is 65537:
*”/**
* RSA keypair generation. Standard algorithm, minimum key length 512 bit.
* We generate two random primes until we find two where phi is relative
* prime to the public exponent. Default exponent is 65537. It has only bit 0
* and bit 4 set, which makes it particularly efficient.
**/*
if you want a different public exponent you need to create your own provider and integrate it with JCA.
more on the math behind this here.
[ad_2]
solved Java RSA private key generation when public key is known