Code example for BigInteger

Methods: bitLength

0
		return g;
	} 
 
	@Override 
	public String keyType() {
		return "DHG-" + p.bitLength();
	} 
 
	@Override 
	public byte[] fingerprint() { 
		return fingerprint(new BigInteger[] { p, g });
	} 
 
	@Override 
	public byte[] asBytes() { 
		byte[] pb = Util.MPIbytes(p);
		byte[] gb = Util.MPIbytes(g);
		byte[] tb = new byte[pb.length + gb.length];
		System.arraycopy(pb, 0, tb, 0, pb.length);
		System.arraycopy(gb, 0, tb, pb.length, gb.length);
		return tb;