Ruby on Rails Authentication Cheatsheet

Secure user authentication in ruby on rails is discussed here.

Implementing authentication in a typical Rails application is made easy and secure with devise gem.

Install it using: gem 'devise'

Then install it to the user model:

rails generate devise:install

Next, specify which resources (routes) require authenticated access in your routes, config/routes.rb:

To make authentication secure, enforce higher password complexity and allow TLS connections only.

You can try out this PoC, to learn more about it.