ID | Title | Function Name | Test Steps | Expected Result |
DHCP_1 | Verify the dynamic ip address allocation of client | test_dhcp_1request | Send a DHCP discover message from client | All DHCP messages like DHCP discover, DHCP offer, DHCP request and DHCP Ack should be checked. |
DHCP_2 | Verify DHCP NAK message from the server | | 1. Configure pool lets say 20.0.0.1-20.0.0.10 in DHCP server. 2. Let client get the ip address 1. Disconnect this server and Connect another server with IP pool as 80.0.0.1-80.0.0.10 2. Let client send DHCP request message. | When the client sends DHCPREQUEST it will ask for the previous ip address which is not present in pool so the server will send NAK. |
DHCP_3 | Verify releasing an IP from the client to the server to rediscover | test_dhcp_1release | Send DHCP release packet from the client to the server | IP address should get released back to the server and should be able to rediscover |
DHCP_4 | Multiple dhcp servers | | Let there be multiple DHCP servers. Start a dhcp client from one host. | IP address should get allocated to the host from one of the DHCP servers. |
DHCP_5 | Verify DHCP decline message from the client | | 1. You need two clients. One static and one through DHCP server. 2. Try to first assign ip address to dhcp client, reboot the client or just remove it from network. 3. Meanwhile give the same static ip to another client. 4. Now connect the dhcp client. | When the server assigns the ip address the client will do gracious arp and as static ip is already present it will send DHCPDECLINE message to the Server. |
DHCP_6 | Verify restarting the dhcp client | test_dhcp_client_request_after_reboot | 1. Restart the client which has got previously leased IP address. 2. Check for DHCP Ack message | If the requested IP address can be used by the client, the DHCP server responds with a DHCPAck message. |
DHCP_7 | Verify multiple client scenario | test_dhcp_Nrequest | Let there be multiple hosts and generate a multiple DHCP request messages | Server should be able to give ip address to all the hosts. |
DHCP_8 | check for Fail over mechanism in dhcp | | Let there be 2 dhcp servers in the same subnet or scope. Make one dhcp server down | If a DHCP server1 is no longer reachable, then client is able to extend the lease on its current IP address by contacting another DHCP server2. |
DHCP_9 | Verify DHCP client renewing State | | After T1 timer expires, a DHCP request message which is unicast is being sent to the same server | Since the server is up and reachable , it should respond back with DHCP Ack packet |
DHCP_10 | Verify the client behavior when DHCP server is rebooted. | test_dhcp_server_after_reboot | 1. Send a DHCP discover packet . 2. Send a DHCP request packet from the client. 3. Make the DHCP server down. 4. Make the DHCP server up. | 1. DHCP offer packet generated. 2. DHCP Ack packet generated. 3. Client should have the same ip till the lease time expires. 4. DHCP Ack should be sent from the server. |
DHCP_11 | Verify generation of DHCP inform message | | 1. Let client send a DHCP inform message with its own ip address in ciaddr field. 2. Check for DHCP ACk message | DHCP Ack message should be sent from the server which includes the needed parameters in the appropriate DHCP option fields |
DHCP_12 | DHCP starvation attack | test_dhcp_starvation | Send a lot of dummy DHCP requests, with random source Mac address (using Scapy) | After few second, there is no more IP addresses available in the pool, thus successfully performing denial of service attack to other network client. |
DHCP_13 | Verify DHCP Relay functionality | | Make ONOS as DHCP relay agent and Send a DHCP discover message from the client. This inserts the option 82. | ONOS should forward the DHCP server reply to the client |
DHVP_14 | Verify sending DHCP discover packet twice | test_dhcp_same_client_multiple_discover | Send DHCP discover packet twice from the client. | DHCP server should give the same ip to the client. |
DHCP_15 | Verify sending DHCP request packet twice | test_dhcp_same_client_multiple_request | Send the DHCP request packet twice form the client | DHCP Ack should be sent. |
DHCP_16 | Verify ip address assignment when dhcp request and offer ip are different | test_dhcp_server_nak_packet | 1. Send a DHCP discover message from the client. 2. Send DHCP request message with a different ip. | 1. DHCP offer should be sent from server. 2. DHCP NAK should be sent from the server. |
DHCP_17 | Verify ip address assignment is successful when desired ip is sent. | test_dhcp_client_desired_address | Send a DHCP discover packet with the desired ip which is in the server address pool. | DHCP ip address assignment should be successful. |
DHCP_18 | Verify ip address assignment when desired ip is sent which is out of the pool. | test_dhcp_client_desired_address_out_of_pool | Send a DHCP discover packet with the desired ip which is out of the server address pool. | DHCP NAK message should be sent |
DHCP_19 | Verify ip address assignment with the lease time information specified. | test_dhcp_lease_packet | Send a DHCP discover packet with the least time mentioned. | DHCP ip address assignment should be successful with the mentioned lease time. |
DHCP_20 | Verify sending N releases from the client | test_dhcp_Nrelease | Send multiple DHCP release packet from the client to the server | All IP addresses should get released back to the server and should be able to rediscover |
DHCP_21 | Verify broadcast address in dhcp offer | test_dhcp_client_expected_broadcast_address | 1. Send DHCP discover message. 2. Extract option broadcast address from dhcp offer message. 3. Check with your server configuration | Broadcast address should match |
DHCP_22 | Verify dns address in dhcp offer | test_dhcp_client_expected_dns_address | 1. Send DHCP discover message. 2. Extract option dns address from dhcp offer message. 3. Check with your server configuration | Dns address should match |
DHCP_23 | Verify router address in dhcp offer | test_dhcp_client_expected_router_address | 1. Send DHCP discover message. 2. Extract option router address from dhcp offer message. 3. Check with your server configuration | Router address should match |
DHCP_24 | Verify Subnet mask in dhcp offer | test_dhcp_client_expected_subnet_mask | 1.Send DHCP discover message. 2.Extract option Subnet mask from dhcp offer message. 3.Check with your server configuration | Subnet mask should match |
DHCP_25 | Verify sending dhcp discover with wrong broadcast address | test_dhcp_client_sends_dhcp_request_with_wrong_broadcast_address | 1. Send DHCP discover message with wrong broadcast address. 2. Extract option Broadcast address from dhcp offer message. 3. Check with your server configuration | Server configuration broadcast address should be seen in dhcp offer |
DHCP_26 | Verify sending dhcp discover with wrong DNS address | test_dhcp_client_sends_dhcp_request_with_wrong_dns_address | 1. Send DHCP discover message with wrong dns address. 2. Extract option DNS server from dhcp offer message. 3. Check with your server configuration | Server configuration DNS address should be seen in dhcp offer |
DHCP_27 | Verify sending dhcp discover with wrong router address | test_dhcp_client_sends_dhcp_request_with_wrong_router_address | 1. Send DHCP discover message with wrong router address. 2. Extract option router address from dhcp offer message. 3. Check with your server configuration | Server configuration Router address should be seen in dhcp offer |
DHCP_28 | Verify sending dhcp discover with wrong Subnet mask address | test_dhcp_client_sends_dhcp_request_with_wrong_subnet_mask | 1. Send DHCP discover message with wrong Subnet mask. 2. Extract option Subnet mask address from dhcp offer message. 3. Check with your server configuration | Server configuration Subnet mask should be seen in dhcp offer |
DHCP_29 | Verify dhcp client renew process | test_dhcp_client_renew_time | After T1 timer expires, a DHCP request message which is unicast is being sent to the same server | Since the server is up and reachable, it should respond back with DHCP Ack packet |
DHCP_30 | Verify dhcp client rebind process | test_dhcp_client_rebind_time | After Rebind timer expires, a DHCP request message which is broadcast is being sent. | Since the server is up and reachable, it should respond back with DHCP Ack packet |
DHCP_31 | Verify lease time check | test_dhcp_lease_packet | 1. Send DHCP discover message. 2. Send DHCP request now. 3. Extract the option lease time in DHCP ACK packet. | 1. DHCP offer should be received. 2. DHCP Ack packet should be received with the default lease time of 600 sec. |
DHCP_32 | Measure average no. of transactions in DHCP server in 1 second | test_dhcp_server_transactions_per_second | 1. Send DHCP discover and DHCP request messages from different MAC addresses. 2. Calculate total running time and total no. of transactions after repeating the procedure for 3 times. 3. Divide total no. of transactions with total running time. | 1. DHCP offer and DHCP Ack should be received until there are free addresses in pool of DHCP server. |
DHCP_33 | Measure average no. of consecutive successful transactions in DHCP server in 1 second | test_dhcp_server_consecutive_successes_per_second | 1. Send DHCP discover and DHCP request messages from different MAC addresses. 2. Calculate total running time and total no. of successful transactions after repeating the procedure for 3 times. 3. Divide total no. of successful transactions with total running time. | 1. DHCP offer and DHCP Ack should be received until there are free addresses in pool of DHCP server. |
DHCP_34 | Measure average number of clients (DHCP discover) in 1 second | test_dhcp_server_clients_per_second | 1. Send DHCP discover packets continuously from different mac address. 2.Calculate total running time and total no. Of clients after repeating the procedure for 3 times. 3. Divide total no. of clients with total running time. | DHCP offer should be received until DHCP server pool ip address are exhausted. |
DHCP_35 | Measure average no. of consecutive successful clients in DHCP server in 1 second | test_dhcp_server_consecutive_successful_clients_per_second | 1. Send DHCP discover packets continuously from different mac address. 2.Calculate total running time and total no. Of successful clients after repeating the procedure for 3 times. 3. Divide total no. Of successful clients with total running time. | DHCP offer should be received until DHCP server pool ip address are exhausted. |