1670 Web Server Commands
Example
The following example displays how to specify the country as "us."
console(config-crypto-cert)#country us
crypto certificate generate
Use the crypto certificate generate command in Global Configuration mode
to generate a self-signed HTTPS certificate.
Syntax
crypto certificate
number
generate
number
— Specifies the certificate number. (Range: 1–2)
generate
— Regenerates the SSL RSA key.
Default Configuration
This command has no default configuration.
Command Mode
Global Configuration mode
User Guidelines
This command is not saved in the router switch configuration; however, the
certificate and keys generated by this command are saved in the private
configuration. This saved information is never displayed to the user or backed
up to another switch. If the RSA keys do not exist, the generate parameter
must be used. To save the generated certificate and keys on the local switch
and distribute the certificate across a stack, save the configuration.
Otherwise, the certificate and keys will not be available after the next reboot.
Example
The following example generates a self-signed HTTPS certificate.
console(config-crypto-cert)#common-name DELL
console(config-crypto-cert)#country USA
console(config-crypto-cert)#Duration 3650
2CSPC4.XCT-SWUM2XX1.book Page 1670 Monday, October 3, 2011 11:05 AM