雅加达和玻璃鱼 - 基本身份验证工程,形式身份验证不会

发布于 2025-02-06 15:30:31 字数 441 浏览 2 评论 0原文

我对网络开发很新。目前,我正在尝试在我的雅加达应用程序上进行基于表格的身份验证。我设法在Glassfish 6.0.0上创建了一个领域,并将其集成到Web.xml描述符上。我设法使基本的身份验证起作用,但是当我尝试更改以形成身份验证时,我会每天都想登录403状态代码。每次将邮政请求发送给J_Security_Check,以及403状态代码时,我都会收到以下错误:

*** Web9102:Web登录失败: com.sun.enterprise.security.auth.login.common.loginexception

:登录失败:安全例外***,对我说太多。

我想创建一个表单身份验证,以便使用J_Security_Check使用Postman的Form-Data格式登录。如果我不能这样做,是否有一种方法可以创建自定义端点以发送请求以进行身份​​验证?

I am pretty new into web development. Currently I am trying to do an Form Based Authentication on my Jakarta app. I managed to create a realm on Glassfish 6.0.0 and to integrate it on the web.xml descriptor. I managed to make the Basic Authentication work, but when I try it to change to Form Authentication I get an 403 status code ever time I want to login. I got the following error every time I send a POST request to j_security_check with good credentials, along with 403 status code:

***WEB9102: Web Login Failed:
com.sun.enterprise.security.auth.login.common.LoginException

: Login failed: Security Exception*** which doesn't say to much for me.

I wanted to create an Form Authentication in order to use j_security_check to login using form-data format from Postman. If I can not do this, is there a way to create a custom endpoint to send a request in order to authenticate?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

江湖正好 2025-02-13 15:30:31

我发现了一种方法可以完成我目前需要的事情。我刚刚在URL中发送了参数。目前,即使安全性遭受了这种方法的影响,它也是完美的。

I found out a method to do what I needed for the moment. I just sent parameters in URL. For now it is perfect, even though the security suffer with this method.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文