Here you can find the source of getPublicExponent(PublicKey pubk)
public static byte[] getPublicExponent(PublicKey pubk)
//package com.java2s; // it under the terms of the GNU General Public License as published by import java.security.PublicKey; import java.security.interfaces.RSAPublicKey; public class Main { public static byte[] getPublicExponent(PublicKey pubk) { RSAPublicKey rsaKey = (RSAPublicKey) pubk; return rsaKey.getPublicExponent().toByteArray(); }/*from w ww .ja v a 2s. c o m*/ }