Popularity
6.5
Growing
Activity
0.0
Stable
27
5
4
Programming language: Crystal
License: MIT License
Tags:
HTTP
Latest version: v0.2.2
helmet alternatives and similar shards
Based on the "HTTP" category.
Alternatively, view helmet alternatives based on common mentions on social networks and blogs.
-
halite
💎HTTP Requests Client with a chainable REST API, built-in sessions and middlewares. -
cossack
Simple and flexible HTTP client for Crystal with middleware and test support. -
Cable
It's like ActionCable (100% compatible with JS Client), but you know, for Crystal -
http-protection
This library protects against typical web attacks. It was inspired in rack-protection Ruby gem. -
crystal-routing
Extensible library to deal with http request and string based routing in Crystal -
http-params-serializable
The HTTP params parsing module for Crystal 🤓 -
http_parser.cr
Crystal wrapper for Http Parser lib: https://github.com/joyent/http-parser -
multipart.cr
Adds multipart and multipart/form-data support to the crystal standard library -
ContentDisposition
Crystal shard to create HTTP Content-Disposition headers with proper escaping/encoding of filenames -
http_distributor
http server which allows sneaky http request though it. -
crystal-cossack
Simple and flexible HTTP client for Crystal with middleware and test support.
Static code analysis for 29 languages.
Your projects are multi-language. So is SonarQube analysis. Find Bugs, Vulnerabilities, Security Hotspots, and Code Smells so you can release quality code every time. Get started analyzing your projects today for free.
Promo
www.sonarqube.org
Do you think we are missing an alternative of helmet or a related project?
README
Helmet
Helmet helps you secure your Crystal web apps by setting various HTTP headers. It's not a silver bullet, but it can help!
This is a port of the Node.js version of Helmet.
Installation
Add this to your application's shard.yml
:
dependencies:
helmet:
github: EvanHahn/crystal-helmet
Usage
require "http/server"
require "helmet"
server = HTTP::Server.new("0.0.0.0", 8080,
[
Helmet::DNSPrefetchControllerHandler.new,
Helmet::FrameGuardHandler.new,
Helmet::InternetExplorerNoOpenHandler.new,
Helmet::NoSniffHandler.new,
Helmet::StrictTransportSecurityHandler.new(7.day),
Helmet::XSSFilterHandler.new,
]) do |context|
context.response.content_type = "text/plain"
context.response.print "Hello world!"
end
server.listen
Helmet is really just a collection of smaller handlers that set HTTP headers. See them listed in the example above and in the documentation.
Contributing
- Fork it (https://github.com/EvanHahn/crystal-helmet/fork)
- Create your branch (
git checkout -b my-new-feature
) - Commit your changes (
git commit -am 'Add XYZ'
) - Push to the branch (
git push origin my-new-feature
) - Create a new pull request
Contributors
- Evan Hahn - creator, maintainer
- Du Ba Thach - #3