我有自己的登录页面,用户在其中输入用户名/密码。 该用户名/密码用于通过 Keycloak Rest API 登录。
http://localhost:8080/auth/realms/Demo/protocol/openid-connect/token
input - {username,password,grant_type,client_secret,client_id}
Run Code Online (Sandbox Code Playgroud)
我得到的回应是access token。
现在我希望启用身份验证器 ( Google Authenticator)。我已经从后端启用了它。现在,如果用户希望通过我的应用程序登录,我的登录页面需要获取以下详细信息。
1.)不知何故,我需要包含在用户名/密码验证后出现在keycloak登录页面上的二维码,以便在用户输入用户名/密码后首次登录时显示在我的登录屏幕上。那么我们是否有任何 API 可以返回 Keycloak 二维码图像作为响应。
2.) 后续登录将有 OTP 字段,因此需要一个 REST api 来传递 OTP 以及用户名/密码。
如果 keycloak 有 REST API,请提供帮助。通过 Javascript 集成。
与此处用例 1 中描述的流程类似
只是想使用keycloak作为数据库,为我做所有操作,输入将是我的屏幕。我确实希望在登录时重定向 URL,但应该独立部署。
authentication user-registration keycloak keycloak-services multi-factor-authentication
我需要从 C# 控制台应用程序访问 SQL 表数据的某些部分。我需要帮助从 C# 建立服务器连接。
数据库详细信息:
Server type : Database Engine
Authentication : Active Directory-Universal with MFA support.
Run Code Online (Sandbox Code Playgroud)
另请让我知道我应该如何提供我的连接属性?
c# azure azure-active-directory azure-sql-database multi-factor-authentication
我正在尝试在 AWS CLI 上检索会话令牌,如下所示:
aws sts get-session-token --serial-number arn-string --token-code mfacode
在哪里
arn-string从 IAM 管理控制台复制,分配的 MFA 设备的安全凭证,格式如下arn:aws:iam:<number>:mfa/<name>mfacode取自已注册的虚拟 MFA 设备An error occurred (InvalidClientTokenId) when calling the GetSessionToken operation: The security token included in the request is invalid.
但是,我使用该 MFA 设备在浏览器中登录控制台就可以了
我的 ~/.aws/ 中只有一个默认配置文件,但我不知道这会产生什么影响。
--token-code,希望它提示我输入 MFA 设备令牌——同样的错误arn:aws:iam:<number>:user/<name>-- 与预期相同的错误,因为aws get-session-id help 明确指出它需要是 MFA 设备的 arn我认为这与 arn-string 而不是令牌有关,但是什么?任何关于导致此问题的原因的想法都非常受欢迎。
问候,奥拉夫
我刚刚注册了一个Oracle Cloud的账户
登录后,系统似乎自动为我创建了一个租户,并将我添加到名为 的身份提供者中oracleidentitycloudservice。
他们还创建了一个以 开头的用户oracleidentitycloudservice/username。
这是身份用户页面,他们两个都是我。其中之一是联合的,oracleidentitycloudservice会自动创建。

我可以为第二个帐户启用 MFA。
但我无法启用 MFA 帐户oracleidentitycloudservice/username:

当我想登录Identity Console页面时,我需要使用这个SSO方法:

如果 Identity Console 页面不提供 MFA 功能,这似乎存在风险。这就是我担心的。
问题是:
oracleidentitycloudservice/username?oracleidentitycloudservice/username从 Oracle 基础架构页面启用 MFA?oracleidentitycloudservice/username,这会是一个安全问题吗?我有一个包含多个应用程序客户端的 AWS Cognito 用户池。对于其中两个应用程序客户端,我想强制用户使用多重身份验证 (MFA) 进行身份验证。使用任何其他应用程序客户端登录时,应禁用 MFA。如果我为用户池启用 MFA,它将影响所有应用程序客户端。
在我的研究中,我发现可以创建自定义身份验证流程,如果登录请求来自特定应用程序客户端,我可以实施 MFA。但如果不需要自定义实现,那就太好了。https://docs.aws.amazon.com/cognito/latest/developerguide/amazon-cognito-user-pools-authentication-flow.html#Custom-authentication-flow-and-challenges
除了创建自定义身份验证流程以仅为特定应用程序客户端启用 MFA 之外,还有其他方法吗?
amazon-web-services amazon-cognito multi-factor-authentication
我目前正在尝试自动化我们的网页,但是在访问我们的页面之前,用户会被重定向到 www.login.microsoftonline.com 以输入我发送的短信的用户名、密码和身份验证令牌。输入成功后,用户将被重定向到我们的网页。
尽管我很难找到任何帮助或强大的代码参考,但我已经阅读了多篇文章。
例如我们的工作流程:
目前,当尝试执行以下代码时,cypress 显示: login.microsoftonline.com 拒绝连接
describe('Test', function() {
it('My Test', function() {
cy.request('POST', 'https://login.microsoftonline.com'),
{
auth: {
username: 'myUsername' ,
password: 'myPassword'
}
}
cy.visit('https://example.com')
cy.wait(2000)
cy.contains('Text I expect')
})
})Run Code Online (Sandbox Code Playgroud)
任何帮助将不胜感激,谢谢。
automation azure single-sign-on cypress multi-factor-authentication
我正在使用 AWS CLI 启用仅具有 TOTP MFA(无 SMS)的 MFA 用户池。
aws cognito-idp set-user-pool-mfa-config --user-pool-id xxxx_xxxx --mfa-configuration 可选 --software-token-mfa-configuration Enabled=true
{
"SoftwareTokenMfaConfiguration": {
"Enabled": true
},
"MfaConfiguration": "OPTIONAL"
}
Run Code Online (Sandbox Code Playgroud)
看起来还行吧?但是当我尝试设置用户首选项时,我不断收到此错误:
调用 AdminSetUserMFAPreference 操作时发生错误 (InvalidParameterException):用户尚未设置软件令牌 mfa
命令: aws cognito-idp admin-set-user-mfa-preference --user-pool-id xxxx_xxxx --username username@email.com --software-token-mfa-settings Enabled=true
尝试使用 admin-set-user-preference 也不起作用: aws cognito-idp admin-set-user-settings --user-pool-id us-xxxx-xxxx--username username@email.com --mfa -option DeliveryMedium=EMAIL
调用 AdminSetUserSettings 操作时发生错误 (InvalidParameterException):当前仅支持 phone_number 属性作为 MFA 选项。
我错过了什么?它是否需要文档中未提及的额外配置?
首先,您需要为用户获取 ACCESS_TOKEN 并继续启动 TOTP 过程:
aws cognito-idp associate-software-token --access-token ACCESS_TOKEN
(这将生成一个您可以在 Google Authenticator 中使用的唯一代码)
使用从 …
我正在为我的应用程序使用 Azure SQL,并且从 Management Studio 中,我使用下拉列表中的Active Directory - Universal 和 MFA 选项作为身份验证方法连接到数据库。毫无问题地连接数据库

但当尝试从 Visual Studio 连接管理器连接到数据库时,该方法不可用
这是屏幕抓取
那么如何从 Visual Studio 使用 MFA 连接到我的 Azure DB
active-directory visual-studio azure-sql-database multi-factor-authentication
我的 IAM 用户有两个策略:AdministratorAccess和ForceMultiFactorAuthentication。当附加ForceMultiFactorAuthentication策略时,从 Windows 命令行尝试对存储库执行任何操作时都会收到 403 错误(例如:git clone ..)。当我删除该策略时,我可以使用该存储库(例如:git clone有效)。
我的ForceMultiFactorAuthentication策略是否存在阻止代码提交工作的因素?如何通过多重身份验证正确设置 CodeCommit?
git clone https://git-codecommit...在本地尝试fatal: unable to access 'https://git-codecommit...': The requested URL returned error: 403git clone ..它克隆了存储库。有用。 …amazon-web-services aws-codecommit multi-factor-authentication
我已按照此 AWS 博客使用电子邮件 TOTP(基于时间的一次性密码)作为 MFA 为我的网站实施自定义身份验证流程: https ://aws.amazon.com/blogs/mobile/extending-amazon-cognito-with -email-otp-for-2fa-using-amazon-ses/
基本上它解释了在 Cognito 上如何使用CUSTOM_CHALLENGE和 3 lambda 函数来:
这样我们就可以达到与基于短信的 MFA 相同的效果,只不过代码是作为电子邮件而不是手机上的短信发送的。
请注意,这与 Cognito 用户池设置中的“MFA”部分非常不同:
上述 MFA 适用于手机短信。
遵循博客教程后,我的工作进展顺利。
但是我有两个问题,在网上找不到解决方案:
如何设置发送到用户电子邮件的一次性密码的过期时间?\
我确信有一个过期时间,并且我相信它是 10 分钟,但文档却找不到。
如何允许 cognito 记住该设备,以便仅当用户尝试从与之前设备不同的设备登录时才需要将电子邮件 TOTP 作为第二因素?
对于 Cognito 设置上基于文本消息的 MFA(或“真正的”MFA),只需在“设备”部分启用即可轻松实现:
Do you want to use a remembered device to suppress the second factor during multi-factor authentication (MFA)?
Run Code Online (Sandbox Code Playgroud)
但是,对于为 2FA 实现电子邮件 OTP 的方法,我该如何执行此操作?
amazon-web-services amazon-cognito multi-factor-authentication
multi-factor-authentication ×10
azure ×2
automation ×1
aws-cli ×1
c# ×1
cypress ×1
keycloak ×1
oracle-cloud-infrastructure ×1
totp ×1