Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9204259
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 17, 20262026-06-17T23:40:10+00:00 2026-06-17T23:40:10+00:00

I am building an application that will allow users to sign in using their

  • 0

I am building an application that will allow users to sign in using their Github authentication credentials. The problem is that, I cannot find anything in the documentation, about restricting access to certain users. For example I want users from a specific set of organizations to be able to login in not all people that just have a github account. Any help?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-17T23:40:11+00:00Added an answer on June 17, 2026 at 11:40 pm

    You have a choice at which point in the cycle you authenticate them, before Github or after Github. Judging from your question you’d like to do this during/after auth. Github allows you to add organisation information, but I haven’t used this so I don’t know how secure that is as a membership signifier, but I’ll assume it’s good enough.

    On auth you’ll get sent back a load of details about the user, in the info key of the auth hash, which is in the Rack env under the key 'omniauth.auth'. If you look at the auth hash returned it will likely have the organisation details, or you could request them at this point. You can run a simple conditional on this, and if the user isn’t in then fail them. If you look at the Sinatra example on the Omniauth wiki you’ll see a point where it says # do whatever you want with the information!. It’s at this point you would check and either pass or fail them (I chose that because it’s a bit clearer than the Rails example, but for Rails you’d just do the same in the action you’d mapped to in the controller). You could raise an exception, or (my choice would be) redirect them to the failure endpoint, it’s up to you.

    It would be a good idea to warn people before they try logging in, if that’s possible.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Building an iPhone OS application that will allow users to anonymously post information to
I am building a web application that will need to allow users to save
I am building a web application that will essentially allow authenticated users access to
I'm building a Page Tab application that will allow Facebook users to make purchases
I'm building a Java application that will allow our users to load a list
I am currently building an application which also allow users to specify their profile
Am building a application that'll allow users to enter values in different currency formats.
I am building a scalable web based conferencing product that will allow users to
I'm building a web application that will essentially allow 'admins' to create forms with
I'm building a web application that will allow team collaboration. That is, a user

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.