Skip to content

Implementation of a HTTP server from scratch using Rust πŸ¦€

Notifications You must be signed in to change notification settings

pythonbyte/http-server-rust

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

6 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

Introduction

This project is an implementation of an HTTP server from scratch using Rust. The server is capable of handling dynamic requests and multiple requests concurrently using threads.

Key Features

  • πŸ”§ Built entirely from scratch, no external HTTP libraries
  • πŸ¦€ Leverages Rust's safety and concurrency features
  • 🌐 Implements core HTTP/1.1 functionalities
  • 🚦 Handles multiple concurrent connections efficiently
  • πŸ“š Educational resource for understanding HTTP internals and Rust networking

Usage

To run the server, execute the following command:

cargo run

The server will start running on 127.0.0.1:4221.

To test the server, open a browser and navigate to

curl -v http://localhost:4221/echo/test

Response

* Connected to localhost (127.0.0.1) port 4221
> GET /echo/test HTTP/1.1
> Host: localhost:4221
> User-Agent: curl/8.7.1
> Accept: */*
>
* Request completely sent off
< HTTP/1.1 200 OK
< Content-Type: text/plain
< Content-Length: 4
<
* Connection #0 to host localhost left intact
test%

About

Implementation of a HTTP server from scratch using Rust πŸ¦€

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages