GWT&证明

时间:2017-02-20 13:36:58

标签: gwt wildfly resty-gwt

我有GWT,RestyGWT,Widlfly

Standalone.xml

    <security-realm name="AdminSslRealm">
      <server-identities>
       <ssl>
        <keystore path="${env.DBO_PATH_CONFIG}/${env.ADMIN_CONSOLE}" keystore-password="console" /> 
       </ssl>
      </server-identities>
     </security-realm>
    </security-realms>
...
    <https-listener name="httpsAdmin" socket-binding="httpsAdmin" security-realm="AdminSslRealm" enable-http2="true" /> 
...    
    <socket-binding name="httpsAdmin" port="${jboss.https.port:8553}" /> 

所以我有两个问题:

1)当我发送第一个JSON时,我有这样的错误

OPTIONS https://localhost:8443/services/v2/admin/test net::ERR_INSECURE_RESPONSE

好的,我进入浏览器https://localhost:8443/services/v2/admin/test。并看到这张照片 enter image description here

我接受这个连接后一切正常 如何让客户端自动接受这样的连接?

2)在此之后,当我发送另一个JSON时,我有使用CORS的问题

XMLHttpRequest cannot load https://localhost:8443/services/v2/admin/test. Response to preflight request doesn't pass access control check: No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'https://127.0.0.1:8888' is therefore not allowed access.

如果没有在WiildFy上包含CORS,我可以解决这个问题吗?

如果我可以帮助解决这些问题的证书?如是。提示如何调整。在Wildfly上我做了,但我不能在GWT SuperDev Mode =(

0 个答案:

没有答案