Skip to content
rithvikzPublic

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

 
 

Latest commit

 

History

4 Commits

Folders and files

Repository files navigation

EX01 Developing a Simple Webserver

Date:15/10/2026

REG NO:26001465

AIM:

To develop a simple webserver to serve html pages and display the list of protocols in TCP/IP Protocol Suite.

DESIGN STEPS:

Step 1:

HTML content creation.

Step 2:

Design of webserver workflow.

Step 3:

Implementation using Python code.

Step 4:

Import the necessary modules.

Step 5:

Define a custom request handler.

Step 6:

Start an HTTP server on a specific port.

Step 7:

Run the Python script to serve web pages.

Step 8:

Serve the HTML pages.

Step 9:

Start the server script and check for errors.

Step 10:

Open a browser and navigate to http://127.0.0.1:8000 (or the assigned port).

PROGRAM:

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Network Protocols Table</title>
    <style>
        body {
            font-family: Arial, sans-serif;
            margin: 30px;
            background-color: #f4f4f4;
        }

        h2 {
            text-align: center;
            color: #333;
        }

        table {
            width: 100%;
            border-collapse: collapse;
            background-color: white;
        }

        th, td {
            border: 1px solid #ccc;
            padding: 12px;
            text-align: left;
        }

        th {
            background-color: #007bff;
            color: white;
        }

        tr:nth-child(even) {
            background-color: #f2f2f2;
        }

        tr:hover {
            background-color: #dbeafe;
        }
    </style>
</head>
<body>

    <h2>List of Network Protocols</h2>

    <table>
        <tr>
            <th>S.No</th>
            <th>Protocol Name</th>
            <th>Port Number</th>
            <th>Purpose</th>
        </tr>

        <tr>
            <td>1</td>
            <td>HTTP</td>
            <td>80</td>
            <td>Transfers web pages</td>
        </tr>

        <tr>
            <td>2</td>
            <td>HTTPS</td>
            <td>443</td>
            <td>Secure web communication</td>
        </tr>

        <tr>
            <td>3</td>
            <td>FTP</td>
            <td>20, 21</td>
            <td>Transfers files</td>
        </tr>

        <tr>
            <td>4</td>
            <td>SSH</td>
            <td>22</td>
            <td>Secure remote login</td>
        </tr>

        <tr>
            <td>5</td>
            <td>Telnet</td>
            <td>23</td>
            <td>Remote login without encryption</td>
        </tr>

        <tr>
            <td>6</td>
            <td>SMTP</td>
            <td>25</td>
            <td>Sends emails</td>
        </tr>

        <tr>
            <td>7</td>
            <td>DNS</td>
            <td>53</td>
            <td>Translates domain names into IP addresses</td>
        </tr>

        <tr>
            <td>8</td>
            <td>DHCP</td>
            <td>67, 68</td>
            <td>Automatically assigns IP addresses</td>
        </tr>

        <tr>
            <td>9</td>
            <td>POP3</td>
            <td>110</td>
            <td>Retrieves emails</td>
        </tr>

        <tr>
            <td>10</td>
            <td>IMAP</td>
            <td>143</td>
            <td>Manages emails on a mail server</td>
        </tr>

        <tr>
            <td>11</td>
            <td>TCP</td>
            <td>—</td>
            <td>Provides reliable data transmission</td>
        </tr>

        <tr>
            <td>12</td>
            <td>UDP</td>
            <td>—</td>
            <td>Provides connectionless data transmission</td>
        </tr>
    </table>

</body>
</html>

OUTPUT:

alt text text

RESULT:

The program for implementing simple webserver is executed successfully.

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages