Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
80 commits
Select commit Hold shift + click to select a range
4266057
[IMP] Move files in a subdirectory
max3903 Mar 26, 2018
05cebfa
[MIG] auth_saml: Migration to 11.0
max3903 Mar 26, 2018
06b6be5
Typo
yvaucher Nov 22, 2018
4737908
[UPD] Update auth_saml.pot
oca-travis Dec 12, 2018
4a245af
[ADD] icon.png
OCA-git-bot Apr 3, 2019
e247013
[FIX] auth_saml: Remove broken symlink
pedrobaeza Aug 21, 2019
1d96dd2
[FIX] auth_saml: Fix KeyError using auth_oauth module. (#149)
moylop260 Nov 29, 2019
bb58bec
[UPD] Update auth_saml.pot
oca-travis Nov 29, 2019
3ccf6c0
Update translation files
oca-transbot Nov 29, 2019
20a2ae5
[FIX] dependencies
Nov 30, 2019
5396272
[MIG] auth_saml to 12.0
gurneyalex Dec 11, 2018
ff1f889
[MIG][REF] General cleanup for migration
Mar 19, 2020
25229c2
[UPD] README.rst
OCA-git-bot Mar 27, 2020
11a3a64
FIX auth_saml committing saml_access_token otherwise login_and_redire…
eLBati Nov 16, 2020
5ffd96c
[UPD] Update auth_saml.pot
oca-travis Nov 30, 2020
f8ee8a5
Update translation files
oca-transbot Nov 30, 2020
27614c9
auth_saml 12.0.1.0.1
OCA-git-bot Feb 2, 2021
d847c4b
[IMP] auth_saml: black, isort, prettier
theangryangel Jun 25, 2021
6299175
[MIG] auth_saml: Migration to 14.0
theangryangel Jun 25, 2021
9e5db5f
auth_saml: declare debian dependency
simahawk Jan 14, 2022
8ad1927
auth_saml 14.0.1.0.1
OCA-git-bot Jan 14, 2022
91ffd96
[IMP] auth_saml: black, isort, prettier
Camille0907 Jan 26, 2022
890c4ed
[MIG] auth_saml: Migration to 15.0
Camille0907 Jan 26, 2022
612dcc1
[UPD] Update auth_saml.pot
Feb 14, 2022
26fe4cb
Translated using Weblate (French)
vincent-hatakeyama Feb 15, 2022
d94be24
🚑 Fix the module by adding a transaction to commit the token
vincent-hatakeyama Feb 14, 2022
8137c8b
[UPD] Update auth_saml.pot
Mar 31, 2022
2328ed1
[UPD] README.rst
OCA-git-bot Mar 31, 2022
e42e11d
auth_saml 15.0.1.1.0
OCA-git-bot Mar 31, 2022
45f64c6
Update translation files
oca-transbot Mar 31, 2022
1862bf2
Translated using Weblate (French)
vincent-hatakeyama Apr 4, 2022
4cdc6cb
Place upper bound in cryptography indirect dependency
sbidoul Oct 5, 2022
6662c31
auth_saml 15.0.1.1.1
OCA-git-bot Oct 5, 2022
32401bd
[ADD] auth_saml: Improve login page
vincent-hatakeyama Feb 21, 2023
f1f62dc
[ADD] auth_saml: handle redirect parameter in the URI
vincent-hatakeyama Feb 24, 2023
737acfe
[MIG] auth_saml: Migration to 16.0
szekawong Mar 27, 2023
2cfb401
[UPD] Update auth_saml.pot
Mar 28, 2023
d36958a
[UPD] README.rst
OCA-git-bot Mar 28, 2023
f646746
Update translation files
weblate Mar 28, 2023
9d2cb31
[FIX]auth_saml: fix singleton error.
jesusVMayor May 3, 2023
0e9aed8
auth_saml 16.0.1.0.1
OCA-git-bot Jul 2, 2023
b56050a
auth_saml: add maintainer
vincent-hatakeyama Jul 4, 2023
d5ba68d
[UPD] README.rst
OCA-git-bot Aug 12, 2023
5d4a4e0
auth_saml 16.0.1.0.2
OCA-git-bot Aug 12, 2023
d1243a6
Added translation using Weblate (Spanish)
Ivorra78 Aug 25, 2023
506c3a7
[UPD] README.rst
OCA-git-bot Sep 3, 2023
e924d29
Update translation files
weblate Oct 9, 2023
d41f138
Small bugfix, RelayState can be empty
tb-flyt Dec 15, 2023
b44de05
[BOT] post-merge updates
OCA-git-bot Dec 15, 2023
9608e57
Added translation using Weblate (Italian)
mymage Dec 28, 2023
0d28edd
FIX auth_saml: password reset when deactivating the config settings
leemannd Jan 3, 2024
3af5125
[BOT] post-merge updates
OCA-git-bot Jan 8, 2024
cc76a1e
[MIG] auth_saml: pre-commit
astirpe Apr 8, 2024
46abf9c
[MIG] auth_saml: migrate to V17
astirpe Apr 8, 2024
e328b08
[FIX] auth_saml: update signin method
vincent-hatakeyama Jun 12, 2024
11c1ddf
[IMP] auth_saml: Allow admin/managers to edit User SAML information
aronabencherif May 13, 2024
4306126
[MIG] Improved test coverege
oussjarrousse Aug 6, 2024
81ba9cc
[UPD] Update auth_saml.pot
Aug 20, 2024
6cc35c5
[BOT] post-merge updates
OCA-git-bot Aug 20, 2024
145511d
[IMP] auth_saml: pre-commit auto fixes
BT-dlagin Jan 7, 2025
cd82072
[18.0][MIG] auth_saml: Migration to 18.0
BT-dlagin Jan 7, 2025
6f5aa0a
[UPD] Update auth_saml.pot
Jan 15, 2025
6da74ae
Translated using Weblate (French)
vincent-hatakeyama Jan 27, 2025
7065aff
[FIX] auth_saml: fix getting uid from authenticate return value
StefanRijnhart Apr 9, 2025
afe0a66
[BOT] post-merge updates
OCA-git-bot Apr 10, 2025
1b3fcbe
[FIX] auth_saml: avoid redirecting when there is a SAML error
vincent-hatakeyama Feb 11, 2025
2691889
[BOT] post-merge updates
OCA-git-bot May 13, 2025
55a348d
[FIX] auth_saml: message indicates that a key is found incorrectly
vincent-hatakeyama Jan 28, 2025
c092a0b
[IMP] auth_saml: download the provider metadata
gurneyalex Jan 9, 2024
7e341ae
[IMP] auth_saml: only lock providers being updated
Ricardoalso May 3, 2024
482508f
[IMP] auth_saml: only write value that changes
vincent-hatakeyama Jan 28, 2025
c61a41c
[BOT] post-merge updates
OCA-git-bot Sep 11, 2025
bb20150
Translated using Weblate (Italian)
mymage Sep 26, 2025
26a94dc
[IMP] auth_saml: pre-commit auto fixes
vincent-hatakeyama Mar 26, 2026
734e338
[MIG] sql constraint in model.constraint
michotm Dec 1, 2025
033e2ec
[FIX] auth_saml: fix typo that causes infinite recursion
johnw-bluemark Apr 28, 2026
35f1ef4
[MIG] auth_saml: Migration to 19.0
vincent-hatakeyama Mar 26, 2026
f0ad81c
[FIX] auth_saml: do not crash if no users
len-foss Oct 10, 2025
aa620b3
[FIX] auth_saml: fix sending password change mail when blanking password
vincent-hatakeyama Feb 12, 2026
9ca909d
[IMP] auth_saml: user provisioning on login
vincent-hatakeyama May 13, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
197 changes: 197 additions & 0 deletions auth_saml/README.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,197 @@
.. image:: https://odoo-community.org/readme-banner-image
:target: https://odoo-community.org/get-involved?utm_source=readme
:alt: Odoo Community Association

====================
SAML2 Authentication
====================

..
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!! This file is generated by oca-gen-addon-readme !!
!! changes will be overwritten. !!
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!! source digest: sha256:3e5b3bb4044a255d619b8bda0861d58722133ab48366ffd2c2f88c8fbdcc0a5c
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

.. |badge1| image:: https://img.shields.io/badge/maturity-Beta-yellow.png
:target: https://odoo-community.org/page/development-status
:alt: Beta
.. |badge2| image:: https://img.shields.io/badge/license-AGPL--3-blue.png
:target: http://www.gnu.org/licenses/agpl-3.0-standalone.html
:alt: License: AGPL-3
.. |badge3| image:: https://img.shields.io/badge/github-OCA%2Fserver--auth-lightgray.png?logo=github
:target: https://github.com/OCA/server-auth/tree/19.0/auth_saml
:alt: OCA/server-auth
.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png
:target: https://translation.odoo-community.org/projects/server-auth-19-0/server-auth-19-0-auth_saml
:alt: Translate me on Weblate
.. |badge5| image:: https://img.shields.io/badge/runboat-Try%20me-875A7B.png
:target: https://runboat.odoo-community.org/builds?repo=OCA/server-auth&target_branch=19.0
:alt: Try me on Runboat

|badge1| |badge2| |badge3| |badge4| |badge5|

Let users log into Odoo via an SAML2 identity provider.

This module allows to deport the management of users and passwords in an
external authentication system to provide SSO functionality (Single Sign
On) between Odoo and other applications of your ecosystem.

**Benefits**:

- Reducing the time spent typing different passwords for different
accounts.
- Reducing the time spent in IT support for password oversights.
- Centralizing authentication systems.
- Securing all input levels / exit / access to multiple systems without
prompting users.
- The centralization of access control information for compliance
testing to different standards.

**Table of contents**

.. contents::
:local:

Installation
============

This addon requires the python module ``pysaml2``.

``pysaml2`` requires the binary ``xmlsec1`` (on Debian or Ubuntu you can
install it with ``apt-get install xmlsec1``)

Configuration
=============

To use this module, you need an IDP server, properly set up.

1. Configure the module according to your IdP’s instructions (Settings >
Users & Companies > SAML Providers).
2. Pre-create your users and set the SAML information against the user.

By default, the module let users have both a password and SAML ids. To
increase security, disable passwords by using the option in Settings.
Note that the admin account can still have a password, even if the
option is activated. Setting the option immediately remove all password
from users with a configured SAML ids.

If all the users have a SAML id in a single provider, you can set
automatic redirection in the provider settings. The autoredirection will
only be done on the active provider with the highest priority. It is
still possible to access the login without redirection by using the
query parameter ``disable_autoredirect``, as in
``https://example.com/web/login?disable_autoredirect=`` The login is
also displayed if there is an error with SAML login, in order to display
any error message.

If you are using Office365 as identity provider, set up the federation
metadata document rather than the document itself. This will allow the
module to refresh the document when needed.

Usage
=====

Users can login with the configured SAML IdP with buttons added in the
login screen.

Known issues / Roadmap
======================

- clean up ``auth_saml.request``

Changelog
=========

18.0.1.0.3 (2025-09-11)
-----------------------

Features
~~~~~~~~

- When using attribute mapping, only write value that changes. Not
writing the value systematically avoids getting security mail on
login/email when there is no real change.

18.0.1.0.2 (2025-05-13)
-----------------------

Bugfixes
~~~~~~~~

- Avoid redirecting when there is a SAML error.

18.0.1.0.0
----------

Initial migration for 18.0.

Bug Tracker
===========

Bugs are tracked on `GitHub Issues <https://github.com/OCA/server-auth/issues>`_.
In case of trouble, please check there if your issue has already been reported.
If you spotted it first, help us to smash it by providing a detailed and welcomed
`feedback <https://github.com/OCA/server-auth/issues/new?body=module:%20auth_saml%0Aversion:%2019.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**>`_.

Do not contact contributors directly about support or help with technical issues.

Credits
=======

Authors
-------

* XCG Consulting

Contributors
------------

- `XCG Consulting <https://xcg-consulting.fr/>`__:

- Florent Aide <florent.aide@xcg-consulting.fr>
- Vincent Hatakeyama <vincent.hatakeyama@xcg-consulting.fr>
- Alexandre Brun
- Houzéfa Abbasbhay <houzefa.abba@xcg-consulting.fr>
- Szeka Wong <szeka.wong@xcg-consulting.fr>

- Jeremy Co Kim Len <jeremy.cokimlen@vinci-concessions.com>
- Jeffery Chen Fan <jeffery9@gmail.com>
- Bhavesh Odedra <bodedra@opensourceintegrators.com>
- `Tecnativa <https://www.tecnativa.com/>`__:

- Jairo Llopis

- `GlodoUK <https://www.glodo.uk/>`__:

- Karl Southern

- `TAKOBI <https://takobi.online/>`__:

- Lorenzo Battistini

Maintainers
-----------

This module is maintained by the OCA.

.. image:: https://odoo-community.org/logo.png
:alt: Odoo Community Association
:target: https://odoo-community.org

OCA, or the Odoo Community Association, is a nonprofit organization whose
mission is to support the collaborative development of Odoo features and
promote its widespread use.

.. |maintainer-vincent-hatakeyama| image:: https://github.com/vincent-hatakeyama.png?size=40px
:target: https://github.com/vincent-hatakeyama
:alt: vincent-hatakeyama

Current `maintainer <https://odoo-community.org/page/maintainer-role>`__:

|maintainer-vincent-hatakeyama|

This module is part of the `OCA/server-auth <https://github.com/OCA/server-auth/tree/19.0/auth_saml>`_ project on GitHub.

You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.
1 change: 1 addition & 0 deletions auth_saml/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
from . import controllers, models, wizards
31 changes: 31 additions & 0 deletions auth_saml/__manifest__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
# Copyright (C) 2020 GlodoUK <https://www.glodo.uk/>
# Copyright (C) 2010-2016, 2022 XCG Consulting <https://orbeet.io/>
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).

{
"name": "SAML2 Authentication",
"version": "19.0.1.0.0",
"category": "Tools",
"author": "XCG Consulting, Odoo Community Association (OCA)",
"maintainers": ["vincent-hatakeyama"],
"website": "https://github.com/OCA/server-auth",
"license": "AGPL-3",
"depends": ["base_setup", "web"],
"external_dependencies": {
"python": ["pysaml2", "responses"],
"bin": ["xmlsec1"],
# special definition used by OCA to install packages
"deb": ["xmlsec1"],
},
"demo": [],
"data": [
"data/ir_config_parameter.xml",
"security/ir.model.access.csv",
"views/auth_saml.xml",
"views/res_config_settings.xml",
"views/res_users.xml",
],
"installable": True,
"auto_install": False,
"development_status": "Beta",
}
3 changes: 3 additions & 0 deletions auth_saml/controllers/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).

from . import main
Loading
Loading