HTML5 <keygen> Tag

Definition and Usage

The <keygen> tag defines a generated key.

Differences Between HTML 4.01 and HTML5

The keygen element is new in HTML.


New : New in HTML5.

Attribute Value Description
autofocusNew disabled Makes the input field focused on page load
challengeNew challenge Specifies that the value of the keygen is set to be challenged when submitted.
disabledNew disabled Disables the keytag field
formNew formname Defines one ore more forms the input field belongs to.
keytypeNew rsa
Specifies the security algorithm of the key.
rsa generates a RSA key.
nameNew fieldname Defines a unique name for the input element. The name attribute is used to collect the fields value when submitted.

Standard Attributes

The <keygen> tag also supports the Standard Attributes in HTML5.

Event Attributes

The <keygen> tag also supports the Event Attributes in HTML5.