mirror of
https://github.com/BookStackApp/BookStack.git
synced 2026-05-04 18:08:46 +03:00
Mix/combine AUTH_METHOD options
#2224
Open
opened 2026-02-05 03:22:27 +03:00 by OVERLORD
·
23 comments
No Branch/Tag Specified
development
l10n_development
release
v26-03
ci_fixing
codeberg-actions
lexical_may_2026
MilnerMart/development
sort_rule_text
GamerClassN7/impersonations-for-admin
Zhey-on/feature/csp-image-css-controls-6033
tortillas5/development
clauvaldez/mfaReset
llm_only
vectors
McTom234/oidc-key-algorithms
docker_env
drawio_rendering
user_permissions
ldap_host_failover
svg_image
prosemirror
captcha_example
fix/video-export
v26.03.4
v26.03.3
v26.03.2
v26.03.1
v26.03
v25.12.9
v25.12.8
v25.12.7
v25.12.6
v25.12.5
v25.12.4
v25.12.3
v25.12.2
v25.12.1
v25.12
v25.11.6
v25.11.5
v25.11.4
v24.11.4
v25.11.3
v25.11.2
v25.11.1
v25.11
v25.07.3
v25.07.2
v25.07.1
v25.07
v25.05.2
v25.05.1
v25.05
v25.02.5
v25.02.4
v25.02.3
v25.02.2
v25.02.1
v25.02
v24.12.1
v24.12
v24.10.3
v24.10.2
v24.10.1
v24.10
v24.05.4
v24.05.3
v24.05.2
v24.05.1
v24.05
v24.02.3
v24.02.2
v24.02.1
v24.02
v23.12.3
v23.12.2
v23.12.1
v23.12
v23.10.4
v23.10.3
v23.10.2
v23.10.1
v23.10
v23.08.3
v23.08.2
v23.08.1
v23.08
v23.06.2
v23.06.1
v23.06
v23.05.2
v23.05.1
v23.05
v23.02.3
v23.02.2
v23.02.1
v23.02
v23.01.1
v23.01
v22.11.1
v22.11
v22.10.2
v22.10.1
v22.10
v22.09.1
v22.09
v22.07.3
v22.07.2
v22.07.1
v22.07
v22.06.2
v22.06.1
v22.06
v22.04.2
v22.04.1
v22.04
v22.03.1
v22.03
v22.02.3
v22.02.2
v22.02.1
v22.02
v21.12.5
v21.12.4
v21.12.3
v21.12.2
v21.12.1
v21.12
v21.11.3
v21.11.2
v21.11.1
v21.11
v21.10.3
v21.10.2
v21.10.1
v21.10
v21.08.6
v21.08.5
v21.08.4
v21.08.3
v21.08.2
v21.08.1
v21.08
v21.05.4
v21.05.3
v21.05.2
v21.05.1
v21.05
v21.04.6
v21.04.5
v21.04.4
v21.04.3
v21.04.2
v21.04.1
v21.04
v0.31.8
v0.31.7
v0.31.6
v0.31.5
v0.31.4
v0.31.3
v0.31.2
v0.31.1
v0.31.0
v0.30.7
v0.30.6
v0.30.5
v0.30.4
v0.30.3
v0.30.2
v0.30.1
v0.30.0
v0.29.3
v0.29.2
v0.29.1
v0.29.0
v0.28.3
v0.28.2
v0.28.1
v0.28.0
v0.27.5
v0.27.4
v0.27.3
v0.27.2
v0.27.1
v0.27
v0.26.4
v0.26.3
v0.26.2
v0.26.1
v0.26.0
v0.25.5
v0.25.4
v0.25.3
v0.25.2
v0.25.1
v0.25.0
v0.24.3
v0.24.2
v0.24.1
v0.24.0
v0.23.2
v0.23.1
v0.23.0
v0.22.0
v0.21.0
v0.20.3
v0.20.2
v0.20.1
v0.20.0
v0.19.0
v0.18.5
v0.18.4
v0.18.3
v0.18.2
v0.18.1
v0.18.0
v0.17.4
v0.17.3
v0.17.2
v0.17.1
v0.17.0
v0.16.3
v0.16.2
v0.16.1
v0.16.0
v0.15.3
v0.15.2
v0.15.1
v0.15.0
v0.14.3
v0.14.2
v0.14.1
v0.14.0
v0.13.1
v0.13.0
v0.12.2
v0.12.1
v0.12.0
v0.11.2
v0.11.1
v0.11.0
v0.10.0
v0.9.3
v0.9.2
v0.9.1
v0.9.0
v0.8.2
v0.8.1
v0.8.0
v0.7.6
v0.7.5
v0.7.4
v0.7.3
0.7.2
v.0.7.1
v0.7.0
v0.6.3
v0.6.2
v0.6.1
v0.6.0
v0.5.0
Labels
Clear labels
🎨 Design
📖 Docs Update
🐛 Bug
🐛 Bug
:cat2:🐈 Possible duplicate
💿 Database
☕ Open to discussion
💻 Front-End
🐕 Support
🚪 Authentication
🌍 Translations
🔌 API Task
🏭 Back-End
⛲ Upstream
🔨 Feature Request
🛠️ Enhancement
🛠️ Enhancement
🛠️ Enhancement
❤️ Happy feedback
🔒 Security
🔍 Pending Validation
💆 UX
📝 WYSIWYG Editor
🌔 Out of scope
🔩 API Request
:octocat: Admin/Meta
🖌️ View Customization
❓ Question
🚀 Priority
🛡️ Blocked
🚚 Export System
♿ A11y
🔧 Maintenance
> Markdown Editor
pull-request
Mirrored from GitHub Pull Request
Milestone
No items
No Milestone
Projects
Clear projects
No project
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: starred/BookStack#2224
Reference in New Issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @pbordon on GitHub (Apr 27, 2021).
Exist the possibility to login in a mixed method: LDAP or simple user registration, defined by user?
@ssddanbrown commented on GitHub (Apr 30, 2021):
Hi @pbordon,
Would you be able to provide insight into the environment where you'd want this within and the benefits this would bring?
@pbordon commented on GitHub (May 3, 2021):
In my organization, we have internal users, connected to an AD and external users, which are many and vary over time. Therefore I wanted to implement the login via LDAP for internal users and for external users to register separately.
@ssddanbrown commented on GitHub (Nov 8, 2022):
Updating this to be generic to methods, and merging similar issues into this.
@abulgatz commented on GitHub (Feb 5, 2023):
Any plans to add this to your roadmap or implement this? Internal SSO with guest access seems pretty common.
@ssddanbrown commented on GitHub (Feb 5, 2023):
@abulgatz Probably not anytime too soon, to be totally honest. It's high-risk, low demand, low target audience, high support & maintenance. Therefore it doesn't look worth including at this time.
@Fabsky commented on GitHub (Jul 6, 2023):
I'm in the same case, I mean I've contents for internal users (azure), and content for customers (self register)
@mfatfhg commented on GitHub (Jul 26, 2023):
Hi, I have opened #4401 and because it was closed, I would like to continue the discussion here.
One of the reasons why we would like to see this features was:
This was answered by @ssddanbrown with the following argument:
This would be like changing the electronic door locks against bearded locks in case of power failure before entering the building.
And changing a config only to access your documentation system is not what you want to do in an emergency situation. And not everyone who need access to the system in such a situation has the ability or possibility to do this.
@ssddanbrown commented on GitHub (Apr 24, 2024):
@GitTH Like this:?
Open image here
Third party auth sources work alongside primary auth options, so you may be able to use Azure/Google third party options alongside standard email auth.
@simonpa71 commented on GitHub (Apr 29, 2024):
Plus one for this feature request. LDAP may work or not, but I would like to configure a local Admin access anytime. Gitea has this feature, and it makes it easy to configure an admin for mainenance and config, without depending on LDAP, while importing local users with LDPAP. My scenario is simpler than generic mix and match, and could be a starting point.
@CamaroSS commented on GitHub (Jun 10, 2024):
This feature would be very useful. This way we would be able to sign in from our internal system using SAML2 and have external accounts who sign in using email and password.
@eoli3n commented on GitHub (Oct 29, 2024):
https://github.com/BookStackApp/BookStack/issues/5296
@eoli3n commented on GitHub (Oct 29, 2024):
I strongly disagree, this should be default to be honest. Isn't it as simple as to put a checkbox to be able to trigger local authentication for the current session ?
I worked around this, by moving the admin account as a ldap one, problem is if my AD is down, i'm locked out.
@chunter-ccps commented on GitHub (Feb 18, 2025):
+1 to this request. It is very common for a business to have SAML or LDAP accounts for employees and have email/password based signup for customer accounts.
@schlupmann commented on GitHub (Mar 25, 2025):
Since we needed backend SOAP logout functionality for BookStack, I replaced the OneLogin SAML plugin with SimpleSAMLphp. The main changes involved rewriting Saml2Controller.php and Saml2Service.php, as well as adding configuration files to the app/Config directory. The integration now works as intended with the latest SimpleSAMLphp library (LGPL-licensed) installed in the vendor folder.
This to say that we have been using SimpleSAMLphp with two different identity providers: a local LDAP (with SimpleSAMLphp acting as the IDP) and a French national education SAML ID provider. Both are running seamlessly together for Moodle and ResourceSpace. The same can be set up for Bookstack as well. SimpleSAMLphp supports multiple IDPs and SPs.
If Dan sees value in this and there’s a need for it, I’m happy to clean up the code and provide it.
Also, many thanks to Dan for creating this awesome software!
@timhallmann commented on GitHub (Mar 28, 2025):
Hello @schlupmann, thank you for mentioning your setup! I'm certainly interested in seeing how it works. If you're comfortable publishing the current version, I'd also be happy to take a look at the code as-is.
@schlupmann commented on GitHub (Mar 28, 2025):
@timhallmann,
You can have a look at the SOAP / backend logout with saml2 for Bookstack here : [BookStack_saml2_SOAP](https://github.com/BookStackApp/BookStack/compare/development...schlupmann:BookStack_saml2_SOAP:development)
This is not a cleaned-up version, and the integration with BookStack's SAML2 configuration is quite limited. I prefer working directly with SimpleSAMLphp's configuration, which I’ve set up in the added /app/Config/simplesamlphp folder. However, if there's interest, it wouldn't be too difficult to migrate most standard configuration settings into the /app/Config/saml2.php file and eliminate the "dirty" autoloading of the SimpleSAMLphp library.
To set up SimpleSAMLphp, please refer to the official documentation. The main steps are as follows:
Short explanation of backend logout flow :
Routes Configuration: Web routes in bookstacks routes/web.php define SAML endpoints that receive IdP logout requests and direct them to Saml2Controller
Saml2Controller.php:
Houses main back-channel logout logic in handleSingleLogout():
Implements logoutFromIdpBackChannel() method which:
@timhallmann commented on GitHub (Mar 31, 2025):
It's not relevant to this issue, but here is a link to my OIDC extension based on the work by @schlupmann -- thanks again!
@voxain commented on GitHub (Jul 16, 2025):
+1 on this. We want to use BookStack alongside our emergency documentation system for documentation. In case everything comes crashing down, it'd be handy to at least have a universal admin login or token that always works, just in case, preferrably without changing the login method in the config.
@kilian-goetz commented on GitHub (Jul 31, 2025):
Greetings,
I agree with this feature. We need two authentication methods at the same time: OIDC (for users) and classic authentication for the administration account, as well as a backup system in case the OIDC provider is down.
@bwint commented on GitHub (Dec 3, 2025):
+1 for this feature.
Would be great to be able to use standard/local authentication as backup in case the primary authentication provider is down.
@swtgmxat commented on GitHub (Dec 3, 2025):
Also +1 very important feature to have two LOGIN methods in parallel. E.g. LDAP is down, local admin should still work. Also for permission testing very helpful to have a local test user. all the best
@eoli3n commented on GitHub (Dec 3, 2025):
+10, this should be in top priority tier
@holger-dev commented on GitHub (Feb 2, 2026):
+10