Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

revise_auth-jets

Package Overview
Dependencies
Maintainers
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

revise_auth-jets

  • 0.3.3
  • Rubygems
  • Socket score

Version published
Maintainers
1
Created
Source

ReviseAuth

A pure Ruby on Jets authentication system like Devise.

Installation

Add this line to your application's Gemfile:

bundle add "revise_auth-jets"

And then execute the following to generate a User model (optionally adding other fields such as first_name and last_name):

$ jets g revise_auth:model User
$ jets db:migrate
$ jets g revise_auth:views

Add

require "active_record"
ActiveRecord::Base.signed_id_verifier_secret = "custom_verfifier_secret"

in your initializers. Set this as an env var

Create your app/mailer/application_mailer.rb

class ApplicationMailer < ActionMailer::Base
  default from: 'YOUR_EMAIL@gmail.com'
  layout 'mailer'
end

Add your stmp settings in your development.rb ex:

  config.action_mailer.default_url_options = { host: 'localhost', port: 3000, protocol: "https" }
  config.action_mailer.perform_deliveries = true
  config.action_mailer.show_previews = true
  config.action_mailer.delivery_method = :smtp
  config.action_mailer.smtp_settings = {
    address:              'smtp.gmail.com',
    port:                 587,
    domain:               'gmail.com',
    user_name:            'USERNAME@gmail.com',
    password:             'YOUR_PASS',
    authentication:       'plain'}

To get your stmp pass follow these steps

You need to make a password for specific app

Step one: enable 2FA

https://myaccount.google.com/signinoptions/two-step-verification/enroll-welcome Step two: create an app-specific password

https://myaccount.google.com/apppasswords

Usage

ReviseAuth is designed around a single User model.

Roles / Other User Types

ReviseAuth only works with a single model to keep things simple. We recommend adding roles to handle other types of users.

You can accomplish this in a few different ways:

  • A roles attribute on the User model
  • The Rolify gem

FAQs

Package last updated on 27 Sep 2023

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