如何配置 Helidon MP 安全性

huangapple go评论70阅读模式
英文:

How to configure Helidon MP security

问题

我一直在从 github 学习 Helidon MP 的特性,因为它是最可靠的来源之一,由于该框架的社区相对较弱。然而,关于 安全性 的配置和说明有点难以理解。示例在演示应用程序中运行良好,其中用户名、密码、角色和领域被硬编码到 application.yaml 文件中,但由于用户始终存储在数据库中,有时甚至角色也是从包装在角色对象中的数据库中读取的。我确信在 Helidon 安全性方面存在着更具动态性的配置方法;例如,我阅读了关于实现 AuthenticationProviderAuthorizationProvider,并将这些提供者添加到 Security 对象中的内容,但是该对象如何在应用程序中注册呢?任何链接或代码示例都将非常有用。谢谢

英文:

I've been learning Helidon MP features from github as it is one of the most reliable sources due to the weak community of framework. However, the configurations and instructions represented for security is a bit difficult to get. The examples work fine for demo applications where usernames, passwords, roles and realms are hardcoded into application.yaml file but as the users are always stored in database, sometimes even roles are read from database wrapped in a Role object. I'm sure that there exists a more dynamic configuration to Helidon security; for instance, I read about implementing AuthenticationProvider and AuthorizationProvider and adding providers to Security object but how is that object registered in the application? Any links or code samples would be very useful. thanks

答案1

得分: 1

Helidon MP附带了一套完整的与安全提供程序相关的文档,其中包括关于如何扩展安全性的部分

英文:

Helidon MP comes with a full set of documentation related to security providers, including a section on how to extend security.

huangapple
  • 本文由 发表于 2020年10月17日 15:49:42
  • 转载请务必保留本文链接:https://go.coder-hub.com/64400177.html
匿名

发表评论

匿名网友

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen:

确定