sinatra and nginx client cert authentication setup, repository for a follow-along of a guide at https://www.integralist.co.uk/posts/client-cert-authentication/
No puede seleccionar más de 25 temas Los temas deben comenzar con una letra o número, pueden incluir guiones ('-') y pueden tener hasta 35 caracteres de largo.

17 líneas
187B

  1. require 'sinatra'
  2. set :server, %w[thin webrick]
  3. set :bind, '0.0.0.0'
  4. get '/' do
  5. 'Hello world'
  6. end
  7. get '/foo' do
  8. 'Bar'
  9. end
  10. get '/cert' do
  11. request.env['HTTP_X_CLIENTCERT_DN']
  12. end