dieschittigs/contao-tfa-bundle
Composer 安装命令:
composer require dieschittigs/contao-tfa-bundle
包简介
Adds TOTP based Two-Factor Authentication to Contao 4 backend users
README 文档
README
As there is a native support for contao 4.13, this bundle will not be developed further.
Contao Two-Factor Authentication
This bundle enables Two-Factor Authentication (TFA/2FA) via TOTP for Contao backend users. Users with 2FA enabled are not allowed to visit any backend page before typing in the correct access code after having logged in.
The bundle is compatible with Contao 4.4 or newer.
Installation
No matter which method you use to install the package, make sure to run the install tool afterwards so that the additional database column can be created.
Composer
With Composer simply type composer require dieschittigs/contao-tfa-bundle in your Contao installation's root folder.
Contao Manager (Contao 4.5+)
Select Packages > Install Packages and search for contao-tfa-bundle. The button Check & Install will then install it for you.
Usage
To enable Two-Factor Authentication for your account, visit your backend profile and open the "Two-Factor Authentication" section. Scan the displayed QR code with a compatible app (we recommend Google Authenticator, which is available for iOS and Android) and verify by typing in the code generated by your app before hitting Save.
Since the generated code is time-based and thus changes periodically, it is important that your server time is set up correctly. By default the used library for code verification is able to correct for a delay of up to 30 seconds. This can be changed in the security section of your application settings.
You can also force all users to set up Two-Factor Authentication by toggling the checkbox for "Force Two-Factor Authentication" in your application's security settings. This will redirect all users (including yourself as an admin) to a 2FA setup page, before they can access any other page.
In case a user doesn't have access to their code anymore, any admin is able to reset the Two-Factor Authentication on a per-user basis in the user settings. There, admins can also force users to set up Two-Factor Authentication when they next log in, similar to how the setting "Password change required" works.
Caveats
This bundle intercepts all backend requests to redirect users that have yet to authenticate themselves to a 2FA authentication page. As such the users can still log in, but they can't access any backend pages.
If you plan to execute code on behalf of the user, make sure to take the two-factor status into account. Although the user can't visit any pages, they are still fully authenticated by the Symfony security layer, so you'll have to add extra checks to make sure two-factor authentication is complete.
Roadmap
Although we haven't yet decided on any further features, the following might be possible:
- Additional 2FA methods (e.g. mail)
- Backup Codes
dieschittigs/contao-tfa-bundle 适用场景与选型建议
dieschittigs/contao-tfa-bundle 是一款 基于 PHP 开发的 Composer 扩展包,目前已累计 79 次下载、GitHub Stars 达 8, 最近一次更新时间为 2018 年 01 月 08 日, 在 PHP 生态内属于活跃度较高的组件。
它主要适用于以下技术方向: 「Authentication」 「bundle」 「two-factor」 「totp」 「contao」 「tfa」 等业务场景。在实际项目中,围绕这些方向常见需要落地的问题包括:接口对接、性能调优、并发安全、与既有框架(Laravel / ThinkPHP / Yii / Webman 等)的兼容适配,以及生产环境的日志埋点与稳定性保障。
我们在过去多个企业项目中使用过 dieschittigs/contao-tfa-bundle 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。
基于 dieschittigs/contao-tfa-bundle 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。
线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。
承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。
与 dieschittigs/contao-tfa-bundle 相关的其它包
同方向 / 同关键字的高下载量 PHP Composer 包推荐,方便对比选型:
Filament Two Factor Authentication: Google 2FA + Passkey Authentication
Automatically logs-in users if they are already authenticated by a remote source. (e.g. environment variable REMOTE_USER)
2lenet/EasyAdminPlusBundle
GraphQL authentication for your headless Craft CMS applications.
The bundle for easy using json-rpc api on your project
Novactive eZ 2FA Bundle is an Ibexa bundle that provides two-factor authentication for your Ibexa project
统计信息
- 总下载量: 79
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 9
- 点击次数: 0
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: LGPL-3.0
- 更新时间: 2018-01-08