{"id":21430134,"url":"https://github.com/cuba-platform/idp-addon","last_synced_at":"2025-07-14T11:31:14.326Z","repository":{"id":47637618,"uuid":"148157079","full_name":"cuba-platform/idp-addon","owner":"cuba-platform","description":"CUBA IDP Addon","archived":false,"fork":false,"pushed_at":"2021-08-20T08:38:34.000Z","size":341,"stargazers_count":1,"open_issues_count":5,"forks_count":4,"subscribers_count":4,"default_branch":"master","last_synced_at":"2024-04-15T02:04:36.316Z","etag":null,"topics":["cuba-component","cuba-platform","idp","idp-addon","sso"],"latest_commit_sha":null,"homepage":null,"language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/cuba-platform.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2018-09-10T13:09:03.000Z","updated_at":"2021-08-20T08:38:35.000Z","dependencies_parsed_at":"2022-09-15T22:11:31.305Z","dependency_job_id":null,"html_url":"https://github.com/cuba-platform/idp-addon","commit_stats":null,"previous_names":[],"tags_count":4,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cuba-platform%2Fidp-addon","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cuba-platform%2Fidp-addon/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cuba-platform%2Fidp-addon/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cuba-platform%2Fidp-addon/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/cuba-platform","download_url":"https://codeload.github.com/cuba-platform/idp-addon/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":225972028,"owners_count":17553574,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["cuba-component","cuba-platform","idp","idp-addon","sso"],"created_at":"2024-11-22T22:20:57.634Z","updated_at":"2024-11-22T22:20:58.160Z","avatar_url":"https://github.com/cuba-platform.png","language":"Java","funding_links":[],"categories":[],"sub_categories":[],"readme":"# CUBA IDP Add-on\n\n[![license](https://img.shields.io/badge/license-Apache%20License%202.0-blue.svg?style=flat)](http://www.apache.org/licenses/LICENSE-2.0)\n[![Build Status](https://travis-ci.org/cuba-platform/idp-addon.svg?branch=master)](https://travis-ci.org/cuba-platform/idp-addon)\n[![Documentation](https://img.shields.io/badge/documentation-online-03a9f4.svg)](https://github.com/cuba-platform/idp-addon/wiki)\n\n## Overview\n\nSingle-sign-on (SSO) for CUBA applications allows a user to log in to the multiple\nrunning applications by entering a single login name and password once\nin a browser session.\n\n![IDP Login Form](./img/idp_login_form.png)\n\nWhen using SSO, there are two types of applications:\n\n- **Identity Provider (IDP)** is an application that provides user authentication.\nIt contains a login form for entering user credentials and checks the credentials\nagainst the list of registered users. Only one Identity Provider is allowed in\nan SSO environment.\n\n- **Service Provider (SP)** is a regular application that redirects to IDP for\nuser authentication. SP should contain the same list of users as IDP\n(passwords do not matter though). SP provides authorization using CUBA\nsecurity roles and access groups. There may be any number of Service Providers in\nan SSO environment.\n\nAn application can be an Identity Provider and a Service Provider at the same time,\nso you don’t have to setup a dedicated IDP.\n\n\u003e CUBA SSO uses custom HTTP-based protocol and currently does not provide\nintegration with systems using standard authentication protocols like SAML or OIDC.\n\nIn SSO environment, when a user enters a Service Provider URL, the SP redirects\nto the IDP page for entering login name and password. After successful\nauthentication, IDP redirects back to the SP application and the user\ntransparently logs in to SP.\n\nRead addon Wiki for an additional information: [link](https://github.com/cuba-platform/idp-addon/wiki).\n\n## Installation\n\nThe add-on can be added to your project in one of the ways described below. Installation from the Marketplace is the simplest way. The last version of the add-on compatible with the used version of the platform will be installed.\nAlso, you can install the add-on by coordinates choosing the required version of the add-on from the table.\n\nIn case you want to install the add-on by manual editing or by building from sources see the complete add-ons installation guide in [CUBA Platform documentation](https://doc.cuba-platform.com/manual-latest/manual.html#app_components_usage).\n\n### From the Marketplace\n\n1. Open your application in CUBA Studio. Check the latest version of CUBA Studio on the [CUBA Platform site](https://www.cuba-platform.com/download/previous-studio/).\n2. Go to *CUBA -\u003e Marketplace* in the main menu.\n\n ![marketplace](img/marketplace.png)\n\n3. Find the *IDP* add-on there.\n\n ![addons](img/addons.png)\n\n4. Click *Install* and apply the changes.\nThe add-on corresponding to the used platform version will be installed.\n\n### By Coordinates\n\n1. Open your application in CUBA Studio. Check the latest version of CUBA Studio on the [CUBA Platform site](https://www.cuba-platform.com/download/previous-studio/).\n2. Go to *CUBA -\u003e Marketplace* in the main menu.\n3. Click the icon in the upper-right corner.\n\n ![by-coordinates](img/by-coordinates.png)\n\n4. Paste the add-on coordinates in the corresponding field as follows:\n\n `com.haulmont.addon.idp:idp-global:\u003cadd-on version\u003e`\n\n where `\u003cadd-on version\u003e` is compatible with the used version of the CUBA platform.\n\n | Platform Version | Add-on Version |\n|------------------|----------------|\n| 7.2.X            | 0.3.0          |\n| 7.1.X            | 0.2.0          |\n| 7.0.X            | 0.1.1          |\n\n5. Click *Install* and apply the changes. The add-on will be installed to your project.\n\n## Configuration\n\nConfigure add-on with application properties\n([Wiki](https://github.com/cuba-platform/idp-addon/wiki#identity-provider-sso-setup))\n\n## Demo\n\nThis section is a short version of example from\n[Wiki](https://github.com/cuba-platform/idp-addon/wiki/Single-Sign-On-Example).\n\nWe consider an example of setting up SSO for two applications:\nFish and Chips. Fish will be an Identity Provider and Service Provider\nat the same time, Chips will be a Service Provider.\n\n1. Add the **idp-addon** via Studio with the following coordinates (replace x with bug-fix number):\n\n    `com.haulmont.addon.idp:idp-global:0.2.0`\n\n2. Configure aliases in the `hosts` file:\n\n    | Address       | Alias         |\n    |:------------- |:------------- |\n    | 127.0.0.1     | fish          |\n    | 127.0.0.1     | chips         |\n\n3. Configure IDP for the Fish project in `web-app.properties` file of the `web`\nmodule:\n\n    ```\n    cuba.webAppUrl = http://fish:8081/app/\n\n    cuba.idp.serviceProviderUrls = http://fish:8081/app/,http://chips:8082/app/\n    cuba.idp.serviceProviderLogoutUrls = http://fish:8081/app/dispatch/idpc/logout,http://chips:8082/app/dispatch/idpc/logout\n    cuba.idp.trustedServicePassword = mdgh12SSX_pic2\n\n    cuba.web.idp.enabled = true\n    cuba.web.idp.baseUrl = http://fish:8081/app/idp/\n    cuba.web.idp.trustedServicePassword = mdgh12SSX_pic2\n    ```\n\n4. Configure IDP for the \"Chips\" project in `web-app.properties` file of the `web`\nmodule:\n\n    ```\n    cuba.webAppUrl = http://chips:8082/app/\n\n    cuba.web.idp.enabled = true\n    cuba.web.idp.baseUrl = http://fish:8081/app/idp/\n    cuba.web.idp.trustedServicePassword = mdgh12SSX_pic2\n    ```\n\n5. Start the Fish server by launching its `tomcat/bin/startup.*` script or\nvia Gradle: `gradlew start`.\n\n6. Go to [http://fish:8081/app/](http://fish:8081/app/) in your web browser.\nYou will be redirected to the IDP login page. Log in with the `admin / admin`\ncredentials. Create a new user, for example `u1`.\n\n7. Start the Chips server by launching its `tomcat/bin/startup.*` script or\nvia Gradle: `gradlew start`.\n\n8. Go to [http://chips:8082/app/](http://chips:8082/app/) in the same web browser.\nIf you are still logged in to the Fish application, you will be automatically\nlogged in as admin to Chips. Create the same u1 user (password does not matter)\nin the `Chips` application.\n\nNow you can log in as `admin` or `u1` to both applications via the single login form,\nand if you are logged in one application, the login process for the second\napplication will be automatic, bypassing the login form.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcuba-platform%2Fidp-addon","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcuba-platform%2Fidp-addon","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcuba-platform%2Fidp-addon/lists"}