Customise Consent Preferences

We use cookies to help you navigate efficiently and perform certain functions. You will find detailed information about all cookies under each consent category below.

The cookies that are categorised as "Necessary" are stored on your browser as they are essential for enabling the basic functionalities of the site. ... 

Always Active

Necessary cookies are required to enable the basic features of this site, such as providing secure log-in or adjusting your consent preferences. These cookies do not store any personally identifiable data.

No cookies to display.

Functional cookies help perform certain functionalities like sharing the content of the website on social media platforms, collecting feedback, and other third-party features.

No cookies to display.

Analytical cookies are used to understand how visitors interact with the website. These cookies help provide information on metrics such as the number of visitors, bounce rate, traffic source, etc.

No cookies to display.

Performance cookies are used to understand and analyse the key performance indexes of the website which helps in delivering a better user experience for the visitors.

No cookies to display.

Advertisement cookies are used to provide visitors with customised advertisements based on the pages you visited previously and to analyse the effectiveness of the ad campaigns.

No cookies to display.

【IT用語】SAMLとOIDC

SAML (Security Assertion Markup Language) と OIDC (OpenID Connect) は、どちらもユーザー認証に使われる標準プロトコルですが、異なる目的や技術的な仕組みに基づいています。以下は、両者の主な違いを説明します。

  1. プロトコルの種類

    SAML: XMLベースの標準プロトコルで、主にエンタープライズ環境(企業内アプリケーションやシングルサインオン (SSO) システム)でのユーザー認証に使用されます。認証に必要な情報はSAMLアサーションという形式で交換されます。

    OIDC: OAuth 2.0をベースにした、JSON形式の標準プロトコルで、主にウェブやモバイルアプリケーションに対して、ソーシャルログインや認証を行うために使われます。認証情報はIDトークンとしてやりとりされます。
  2. データ形式

    SAML: データはXML形式で表現され、SAMLアサーションという認証情報のセットを交換します。XMLデータはよりリッチで複雑な構造を持ちます。

    OIDC: データはJSON形式で表現され、軽量でモバイルフレンドリーです。特にJSON Web Token (JWT) 形式でIDトークンを送信します。
  3. 用途

    SAML: 主に企業内SSOや、クラウドベースのアプリケーションとの連携に使用されます。例えば、企業のイントラネットや業務用アプリケーションへのシングルサインオンに適しています。

    OIDC: 消費者向けウェブアプリケーションやモバイルアプリケーションでの認証に多く使われ、例えばGoogleやFacebookなどのソーシャルログインでよく見られます。
  4. 通信フロー

    SAML: 通常、ユーザーはIDプロバイダー (IdP) にリダイレクトされて認証を行い、IdPからSAMLアサーションが返送され、サービスプロバイダー (SP) で認証が完了します。SAMLは基本的にブラウザ中心の通信フローです。

    OIDC: OAuth 2.0の認可コードフローと類似し、認証後にIDトークンが発行され、クライアントはトークンを使って認証を行います。ウェブブラウザだけでなく、モバイルアプリやSPA(Single Page Application)とも統合しやすいです。
  5. 認証 vs 認可

    SAML: 主に認証(誰がログインしているのか)に焦点を当てています。認証情報がSAMLアサーションとして交換され、認証後にそのユーザーがどのリソースにアクセスできるかはSAMLでは管理されません。

    OIDC: OIDCは認証プロトコルですが、基盤となるOAuth 2.0は認可(どのリソースにアクセスできるか)を扱うプロトコルです。OIDCはこれにユーザーの認証を追加するため、認証と認可の両方に対応しています。
  6. 適用環境

    SAML: より大規模なエンタープライズ環境やB2BのSSOに適しています。多くの企業や組織が内部のアプリケーションに対してシングルサインオンを提供する際に使います。

    OIDC: ウェブアプリケーションやモバイルアプリケーションに最適化されており、エンドユーザー向けのサービス(例えば、GoogleやFacebookログイン)が主な用途です。
  7. セキュリティモデル

    SAML: XML署名と暗号化が使われ、通信データのセキュリティが強固です。しかし、その分、セットアップが複雑であり、やや重いプロトコルとされています。

    OIDC: OAuth 2.0の仕組みをベースに、JWT署名や暗号化を用いたトークンベースのセキュリティモデルを採用しています。シンプルで軽量な分、セキュリティは依然として高く保たれます。


    結論

    SAMLは、エンタープライズ環境での複雑なSSOやセキュリティ要求が高いシナリオに向いています。

    OIDCは、モバイルアプリケーションや消費者向けウェブサービスでの軽量な認証に適しています。
    それぞれの特性に合わせて、利用する環境やニーズに応じた選択が求められます。