http server
To enable the HTTP server on the router and enable access to the Craft Works Interface (CWI), use the http server command in global configuration mode. To disable the HTTP server, use the no form of this command.
http server [ssl] [ access-group name ]
no http server
Syntax Description
ssl |
(Optional) Enables Secure Socket Layer (SSL). |
access-group name |
(Optional) Enables access to the CWI from IP addresses that meet the conditions of the access control list (ACL) specified for the name argument. |
Command Default
The HTTP server is disabled.
Command Modes
Global configuration
Command History
Release |
Modification |
---|---|
Release 2.0 |
This command was introduced. |
Release 3.2 |
Support for access groups was added. The access-group keyword and name argument were added to support access groups. |
Usage Guidelines
To use this command, you must be in a user group associated with a task group that includes appropriate task IDs. If the user group assignment is preventing you from using a command, contact your AAA administrator for assistance.
Use the http server command to enable the HTTP server on your router.
To display the home page of the router, use a Web browser pointed to http://x.x.x.x , where x.x.x.x is the router IP address. If a name has been set, use http://router-name .
Use the ssl keyword to run HTTP over a secure socket. This command enables the HTTP server to run SSL when accessing web pages or files provided by the HTTP server of the router and disables access through the regular HTTP port.
Enabling the HTTP server enables authentication by default. After the HTTP server has been enabled, you then are prompted to provide a username and password to access web pages on the HTTP server.
Note |
The http server command enables the HTTP server process on Management Ethernet interfaces by default. For information about how to enable HTTP server on other inband interfaces, see the Implementing Management Plane Protection on Cisco IOS XR Software module in System Security Configuration Guide for Cisco CRS Routers. |
Task ID
Task ID |
Operations |
---|---|
config-services |
read, write |
Examples
The following example shows how to enable the HTTP server on the router:
RP/0/RP0/CPU0:router(config)# http server
The following example shows how to enable SSL to run HTTP over a secure socket:
RP/0/RP0/CPU0:router(config)# http server ssl
The following example shows how to enable SSL to run HTTP over a secure socket and to enable access to the CWI from only IP addresses that meet the conditions of the access group named test:
RP/0/RP0/CPU0:router(config)# http server ssl access-group test
The following sample output from the show ipv4 access-lists commands displays the IPv4 access list named test:
RP/0/RP0/CPU0:router# show ipv4 access-lists test
ipv4 access-list test
10 deny ip host 171.71.163.96 any
20 permit ip host 64.102.48.34 any