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.
- Host: GitHub
- URL: https://github.com/v8v88v8v88/nanohttp
- Owner: V8V88V8V88
- Created: 2024-09-23T18:43:45.000Z (8 months ago)
- Default Branch: main
- Last Pushed: 2025-04-06T09:59:53.000Z (about 2 months ago)
- Last Synced: 2025-04-12T06:53:38.720Z (about 2 months ago)
- Topics: c, curl, get, http, http-server, post, server
- Language: C
- Homepage:
- Size: 36.1 KB
- Stars: 2
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
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
```