{"id":33930894,"url":"https://github.com/swindon-rs/http-file-headers","last_synced_at":"2026-04-09T00:02:07.733Z","repository":{"id":62440279,"uuid":"99916358","full_name":"swindon-rs/http-file-headers","owner":"swindon-rs","description":"A library for making fully-features HTTP static file servers in rust using tk-http","archived":false,"fork":false,"pushed_at":"2018-06-27T15:35:34.000Z","size":66,"stargazers_count":5,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-12-13T22:25:29.866Z","etag":null,"topics":["asynchronous","file","http","range-requests","server"],"latest_commit_sha":null,"homepage":null,"language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/swindon-rs.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE-APACHE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2017-08-10T11:35:43.000Z","updated_at":"2018-06-27T15:35:36.000Z","dependencies_parsed_at":"2022-11-01T21:53:04.066Z","dependency_job_id":null,"html_url":"https://github.com/swindon-rs/http-file-headers","commit_stats":null,"previous_names":[],"tags_count":9,"template":false,"template_full_name":null,"purl":"pkg:github/swindon-rs/http-file-headers","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/swindon-rs%2Fhttp-file-headers","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/swindon-rs%2Fhttp-file-headers/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/swindon-rs%2Fhttp-file-headers/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/swindon-rs%2Fhttp-file-headers/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/swindon-rs","download_url":"https://codeload.github.com/swindon-rs/http-file-headers/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/swindon-rs%2Fhttp-file-headers/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31579058,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-08T14:31:17.711Z","status":"ssl_error","status_checked_at":"2026-04-08T14:31:17.202Z","response_time":54,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["asynchronous","file","http","range-requests","server"],"created_at":"2025-12-12T12:18:26.875Z","updated_at":"2026-04-09T00:02:07.692Z","avatar_url":"https://github.com/swindon-rs.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"Http-file-headers Crate\n=======================\n\n[Github](https://github.com/swindon-rs/http-file-headers) |\n[Documentaion](http://docs.rs/http-file-headers) |\n[Examples](https://github.com/swindon-rs/http-file-headers/tree/master/examples) |\n[Crate](https://crates.io/crates/http-file-headers)\n\n\nA framework-agnostic library that parses file-related headers from HTTP request\nand helps serving files including support of:\n\n* `ETag`, `If-None-Match`\n* `Last-Modified`, `If-Modified-Since`\n* `Accept-Ranges`, `Range`, `Content-Range`\n* `Content-Type` using [mime_guess][2]\n* `Accept-Encoding` for serving compressed (gzip and brotli) files\n* Serving `index.html` or similar directory indexes\n\nThe library is not tied to any framework, HTTP or even async library. So\nit's usage is quite verbose (see [example][1]). Still it does most of the\ncomplex work internally and is easily adapted to different needs.\n\nHere are just few things that [example in \u003c 200 LoCs][1] shows:\n\n1. [Tokio](https://tokio.rs) for asynchronous stuff\n2. [Tk-http](https://github.com/swindon-rs/tk-http) serving HTTP\n3. [Futures-cpupool](https://crates.io/crates/futures-cpupool) for\n    offloading reading from disk into separate thread pool\n4. Adding custom headers and error pages\n5. Customizing path where file are served from\n\n[1]: https://github.com/swindon-rs/http-file-headers/tree/master/examples/serve_dir.rs\n[2]: https://github.com/crates/mime_guess\n\n\nLicense\n=======\n\nLicensed under either of\n\n* Apache License, Version 2.0,\n  (./LICENSE-APACHE or http://www.apache.org/licenses/LICENSE-2.0)\n* MIT license (./LICENSE-MIT or http://opensource.org/licenses/MIT)\n  at your option.\n\nContribution\n------------\n\nUnless you explicitly state otherwise, any contribution intentionally\nsubmitted for inclusion in the work by you, as defined in the Apache-2.0\nlicense, shall be dual licensed as above, without any additional terms or\nconditions.\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fswindon-rs%2Fhttp-file-headers","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fswindon-rs%2Fhttp-file-headers","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fswindon-rs%2Fhttp-file-headers/lists"}