Skip to main content

WordPress (CAS SSO)

This guide configures CAS-based SSO for WordPress using wp-cassify and Casdoor as the CAS server.

Step 1: Deploy Casdoor and WordPress

Deploy Casdoor

Install Casdoor. After deployment:

  1. Access the Casdoor web UI via its public/private URL (e.g., http://<casdoor-server-ip>:8000).
  2. Log in with the default admin credentials (or your custom credentials set during deployment).
  3. Confirm the dashboard works (e.g. open Applications, Users) so Casdoor is ready as the CAS IdP.

Deploy WordPress

Deploy WordPress using your preferred method:

  1. Access the WordPress site via its URL (e.g., http://<wordpress-server-ip>).
  2. Complete the initial WordPress setup (create an admin account, site title).
  3. Log in to the WordPress Admin Dashboard (http://<wordpress-server-ip>/wp-admin) to confirm functionality.

Step 2: Create a Casdoor application

Create an application in Casdoor to act as the CAS bridge for WordPress:

  1. Log in to the Casdoor Admin Dashboard.
  2. Navigate to Applications > Add Application
  3. Click Save to create the application.

Add Application

Step 3: Configure wp-cassify

Install the plugin

  1. Log in to the WordPress Admin Dashboard (http://<wordpress-server-ip>/wp-admin).
  2. Navigate to Plugins > Add New.
  3. In the search bar, type "wp-cassify" and select the plugin by "wp-cassify".
  4. Click Install Now, then Activate to enable the plugin.

Configure settings

  1. In the WordPress Admin Dashboard, navigate to Settings > WP-Cassify (the plugin’s configuration page).

  2. Configure User General Settings.

    wp-cassify SettingValue to Enter
    CAS Server Base URLYour Casdoor CAS endpoint (e.g., http://<casdoor-server-ip>:7001/cas/<organization name>/<application name>).
    Create user if not existEnable

    General Settings

  3. Configure User Attribute Synchronization.

    WordPress User FieldCasdoor Attribute NameExample Value
    user_emailemailuser@example.org
    user_nicknamedisplayNameJohn Doe
    display_namedisplayNameJohn Doe

    Attribute Synchronization

Step 4: Test CAS Authentication

Verify the integration works by logging into WordPress via Casdoor:

  1. Log out of the WordPress Admin Dashboard (if logged in).
  2. Access the WordPress login page (http://<wordpress-server-ip>/wp-admin/index.php).
  3. You’ll be redirected to the Casdoor login page. Enter valid Casdoor user credentials.
  4. After successful authentication, Casdoor will redirect you back to WordPress—you should now be logged in (as the synced user). WordPress cas