Skip to content

godofpsychos/single_signon_system

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

46 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

single_signon_system

Secure SSO Login system with Google and Githun OAuth

Welcome to the Single Sign-On (SSO) System project! This project demonstrates a secure sign-in and sign-up system with social login options (GitHub and Google) using JWT authentication.

For live site

Kindly follow the following link

https://frontend-z9oo.onrender.com/Signin

Table of Contents

Architecture

2D Architecture Diagram

2D Architecture Diagram

Frontend (Client):

  • User Interface (UI): Responsible for rendering the user interface and handling user interactions.
  • Social Login (GitHub, Google): Provides options for users to log in using social authentication providers.

Backend (Server):

  • API Endpoints: Offers various API endpoints for frontend communication, including user authentication and data retrieval.
  • Authentication (Passport.js): Implements user authentication strategies, including OAuth for social logins.
  • Database (MongoDB, Redis): Utilizes MongoDB for data storage and Redis for session management.

Features

  • Secure user authentication using JWT tokens.
  • Social login options with GitHub and Google.

Technologies

Frontend:

  • React
  • Bootstrap
  • React Router DOM

Backend:

  • Node.js
  • Express.js
  • Passport.js

Databases:

  • MongoDB
  • Redis(needed for Dashboard where till now used cookie)

Getting Started

  1. Get to following link for starting project locally
    https://github.com/yourusername/sso_localrun
  2. Download the zip and extrat it
  3. Install dependencies for both the frontend and backend:
    cd your-sso-project/frontend
    npm install
    cd your-sso-project/backend
    npm install
  4. Set up environment variables for backend by creating a .env file in the backend directory and adding the required configurations as follows
  5. mongoURI=   your mongobd url
    port = 5000
    gitclientID= gitcliendidvalue
    gitclientSecret = gitclientSecretvalue
    gitcallbackURL = http://localhost:5000/auth/github/callback
    googleclientID= googleclientIDvalue
    googleclientSecret = googleclientSecretvalue
    googlecallbackURL = http://localhost:5000/auth/google/callback
    JWT_SECRET= secretkeyvalue
    frontend_url=http://localhost:3001
  6. Start the frontend and backend servers:
    # In the frontend directory
    npm start
    # In the backend directory
    npm start
  7. Access the application's Frontend at http://localhost:3001 in your web browser.
  8. Access the application's Bakend at http://localhost:5000 in your web browser.

Usage

  • Sign in or sign up using email and password.
  • Alternatively, use the provided social login options with GitHub or Google.
  • Customize and expand the project as needed for your specific use case.

Contributing

Contributions are welcome! Feel free to open issues or pull requests for improvements, bug fixes, or adding new features.

About

Secure SSO Login system with Google and Githun OAuth

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published