简体   繁体   English

在Java中发送之前的SAML请求和签名请求

[英]SAML Request and Sign request before sending in java

Hi I am new to SAML and I want to create a sample request using Java but not Spring. 嗨,我是SAML的新手,我想使用Java创建示例请求,但不使用Spring。 then take that request and sign it and send it to IdP and after that receive the request and be able to read its content.I have tried to make Coveo this work but I didn't know how to create a proper meta data. 然后接受该请求并将其签名并发送给IdP,然后接收到请求并能够读取其内容。我试图使Coveo能够工作,但我不知道如何创建适当的元数据。 Is there any simple library or project to do that. 是否有任何简单的库或项目可以做到这一点。

You need a client side SAML stack . 您需要一个客户端SAML堆栈

You can find Java source examples in the open source ones. 您可以在开放源代码示例中找到Java源代码示例。

Meta data is not mandatory, but it helps a lot as many IdP / SP implementation can directly use it. 元数据不是强制性的,但它可以帮助许多IdP / SP实现直接使用它。

You could use https://www.samltool.com/idp_metadata.php to generate IdP meta data. 您可以使用https://www.samltool.com/idp_metadata.php生成IdP元数据。 As the SAML response is typically digitally signed (when using front-channel binding) you need to input the certificate of the IdP althouth this is not mandatory. 由于SAML响应通常是经过数字签名的(使用前通道绑定时),因此您需要输入IdP算法的证书,这不是强制性的。 So you may just provide some certificate and remove it later on from the meta data if it's not needed. 因此,您可以只提供一些证书,然后在不需要时将其从元数据中删除。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM