An open API service indexing awesome lists of open source software.

https://github.com/v8v88v8v88/nanohttp

A nano lightweight, HTTP server implementation in C.
https://github.com/v8v88v8v88/nanohttp

c curl get http http-server post server

Last synced: about 2 months ago
JSON representation

A nano lightweight, HTTP server implementation in C.

Awesome Lists containing this project

README

        

# nanoHTTP
A nano lightweight, educational HTTP server implementation in C. Ideal for learning network programming basics and understanding HTTP server operations. Features simple GET and POST request handling in a single-file design.

## Run

1. Compile:
```
gcc nanoHTTP.c -o nanohttp.o -lssl -lcrypto -lpthread
```

2. Execute:
```
./nanohttp
```

3. Server runs on port 8080.

## Test

GET request:
```
curl http://localhost:8080
```

POST request:
```
curl -X POST -d "Hello" http://localhost:8080
```