Implement KEYGEN element