在 IBM Websphere 应用服务器上实现 SSL、JAX-WS Web 服务
我尝试让 SSL 在使用 IBM Websphere JAX-WS 运行时创建的 Web 服务上工作已有一段时间了,但无法以某种方式使其工作。
需要您的帮助来解决问题。
这些是我已采取的步骤。
它是一个简单的“添加数字”Web 服务,它将两个数字相加并返回输出。
我在 WAS 7.0 上部署了 Web 服务,
ws 的端点是 http://localhost:9080/WebServiceProject/ AddNumbersSvc/AddNumbersSvc.wsdl
为了配置 ssl,我采取了以下步骤:
在 WAS 管理控制台中,我转到:服务 -> 策略集 -> 应用程序策略集。我选择了默认的 WSHTTPS。复制它并将其重命名为 WS SSL Policy,我不更改其中的任何内容。 接下来,我转到“安全性”->“SSL 证书和密钥管理”->“密钥存储和证书” 我使用自签名证书创建了 ServerKeyStore,使用客户端公钥创建了 ServerTrustStore 然后,我进入安全->SSL证书和密钥管理-> SSL 配置和我创建了一个新的配置 WS SSL conf 将信任存储设置为 ServerTrustStore,将密钥存储设置为 ServerKeyStore 接下来,我进入 WS SSL conf 的 QOP 设置。在那里,我将客户端身份验证设置为必需,将协议设置为 ssl,其余均为默认设置。 然后,我转到“服务”->“策略集”->“通用提供商策略集绑定”。我选择了默认的 WSHTTPS。复制它并将其重命名为 WS SSL Binding。选择了它。比选择的 SSL 传输和选择 WS SSL conf 作为 SSL 设置 最后我去了服务->服务提供商。选择 AddNumbers 服务并应用 WS SSL 策略作为策略集,选择 WS SSL 绑定作为绑定。
现在,当我重申应用程序并尝试通过以下方式执行 ws 时 https://localhost:9080/WebServiceProject/AddNumbersSvc/AddNumbersSvc.wsdl
我得到了 404 :( 而且当我通过 SOAPUi 使用 http 触发 ws 时,我得到了响应,但没有使用 https。
现在请帮助我找出我做错了什么。
I am trying to make SSL work on a webservices created by using IBM Websphere JAX-WS runtime for quite a while now but am unable to make it work somehow.
Need your help in resolving the problem.
These are the steps I have taken.
Its a simple Add Numbers Web service which adds two numbers and returns the output.
I deployed the webservice on WAS 7.0
the endpoint for the ws is http://localhost:9080/WebServiceProject/AddNumbersSvc/AddNumbersSvc.wsdl
Than to configure the ssl I took the following steps:
In WAS admin console I went to: Services->Policy Sets->Application Policy Sets. Than I selected WSHTTPS default. copied it and rename it to WS SSL Policy, I dint chnage anything in it.
Next, I went to Security->SSl ceritificate and key management ->Key stores and certificates I created ServerKeyStore with a self signed certificate and ServerTrustStore with the client public key
Than, I went to Security->SSl ceritificate and key management -> SSL Configurations and I created a new configuration WS SSL conf set the trust store as ServerTrustStore and Keystore as ServerKeyStore
Next, I went to QOP setting of WS SSL conf. There I set client authentication as required , protocol as ssl and rest all default.
Than, I went to Services->Policy Sets->General provider policy set bindings. Than I selected WSHTTPS default. copied it and rename it to WS SSL Binding. seleced it. than selected SSL transport and selected WS SSL conf as SSL settings
Finally I went to Services->Service providers. selected AddNumbers service and apllied WS SSL Policy as policy set and WS SSL Binding as Binding.
Now when i restated the application and tried to execute the ws through
https://localhost:9080/WebServiceProject/AddNumbersSvc/AddNumbersSvc.wsdl
i got a 404 :( and also when i triggered the ws through SOAPUi with http i got the repsonse but not with https.
Now pls help me to figure out what i did wrong .
您需要禁用 http 请求并启用 https,如下所示。
服务器->服务器类型 ->应用服务器>选择服务器>网络集装箱运输链。
禁用 WCInboundDefault。
启用 WCInboundDefaultSecure
You will need to disable http request and enable https as shown below.
Server -> Server Types -> Application servers > select the server > Web container transport chains.
Disable WCInboundDefault.
Enable WCInboundDefaultSecure