Understanding Single Sign-On (SSO): Architecture, Components, and Workflow

This article explains the fundamentals of Single Sign-On (SSO), detailing its centralized authentication principle, the roles of CAS Server, CAS Client, and browser, and walks through the complete login flow with diagrams and code snippets for distributed systems.

Architect Chen
Architect Chen
Architect Chen
Understanding Single Sign-On (SSO): Architecture, Components, and Workflow

What Is Single Sign-On (SSO)?

Single Sign-On (SSO) allows a user to authenticate once and then access multiple trusted applications without re‑entering credentials, improving user experience and simplifying identity management, especially in distributed or multi‑application environments.

Core Principle

The essence of SSO is centralized authentication: the user authenticates only on the SSO server, which then issues a token that other services can trust and validate.

Key Components

CAS Server (Authentication Center) : Handles username/password verification, maintains a global login ticket (TGT), issues service tickets (ST), and coordinates single logout.

CAS Client (Business System) : Does not perform login itself; it intercepts unauthenticated requests, redirects users to the CAS Server, and validates service tickets.

Browser : Carries cookies (TGC) and performs 302 redirects, transmitting tickets between the client and the server.

Architecture Diagram

Technical Sketch

┌──────────┐   │ Browser │   └────┬─────┘        │      ▼   ┌────────────┐          ┌────────────────┐   │ Client A │◄──────►│   SSO Server   │   │ Client B │        │ (Authentication Center) │   │ Client C │        └────────────────┘   └────────────┘

SSO Workflow

User attempts to access a protected resource on Client A.

Client A detects no local session and redirects the browser (302) to the CAS Server.

The CAS Server checks for a TGC cookie; if absent, it presents a login page.

User submits credentials; the CAS Server validates them and issues a Service Ticket (ST).

Client A receives the ST and, without involving the browser, validates the ticket with the CAS Server.

Upon successful validation, the CAS Server returns user information.

Client A creates a local session for the user, completing the login process.

Benefits and Use Cases

SSO greatly reduces the number of login prompts, streamlines session management across services, and centralizes security controls, making it ideal for micro‑service architectures, enterprise portals, and any scenario with multiple inter‑related applications.

Original Source

Signed-in readers can open the original source through BestHub's protected redirect.

Sign in to view source
Republication Notice

This article has been distilled and summarized from source material, then republished for learning and reference. If you believe it infringes your rights, please contactadmin@besthub.devand we will review it promptly.

distributed systemsSecurityAuthenticationCASIdentity ManagementSSOSingle Sign-On
Architect Chen
Written by

Architect Chen

Sharing over a decade of architecture experience from Baidu, Alibaba, and Tencent.

0 followers
Reader feedback

How this landed with the community

Sign in to like

Rate this article

Was this worth your time?

Sign in to rate
Discussion

0 Comments

Thoughtful readers leave field notes, pushback, and hard-won operational detail here.