New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

ident-express

Package Overview
Dependencies
Maintainers
1
Versions
4
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

ident-express

Add results from ident daemon to your express request objects

  • 0.0.3
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
6
decreased by-33.33%
Maintainers
1
Weekly downloads
 
Created
Source

Ident Express

Adds ident authentation to your express.js routes.

How to use (in CoffeeScript):

checkIdent = require 'ident-express'
app.get '/foo', checkIdent, (req, res) ->
  # Do something with req.ident
  console.log "I think you are " + req.ident

Ident

Ident is described in RFC 1413. One important thing to note is that the information returned by identd should only be trusted if you trust the machine running the identd, which is the machine from which the connection has been made (the user/browser/service that is making the GET/POST/PUT request).

nginx

If your express.js app is behind a reverse-proxy such as nginx then the IP address that express.js sees will be those of nginx, not of the original HTTP request that was made to nginx. nginx can set headers that reveal the real IP address. Ident express will make use of the headers X-Real-Port, X-Real-IP, X-Server-Port which can be set by using the following fragment of nginx config:

proxy_set_header X-Real-Port $remote_port;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Server-IP $server_addr;
proxy_set_header X-Server-Port $server_port;

Keywords

FAQs

Package last updated on 21 Feb 2013

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc