@mic2 wrote:
Hi,
We are trying to issue http requests from our app to our servers and get the error
{"_body":{"isTrusted":true},"status":0,"ok":false,"statusText":"","headers":{},"type":3,"url":null}
.The requests work fine through the DevApp and the web view.
I saw that WKWebView needs CORS support, including OPTIONS preflight and verified it’s enabled on our servers (see curl OPTIONS request below).
Any suggestions?
* Trying 18.224.*.*... * Connected to p***r.app (18.224.*.*) port 443 (#0) * successfully set certificate verify locations: * CAfile: none CApath: /etc/ssl/certs * SSLv3, TLS handshake, Client hello (1): * SSLv3, TLS handshake, Server hello (2): * SSLv3, TLS handshake, CERT (11): * SSLv3, TLS handshake, Server key exchange (12): * SSLv3, TLS handshake, Server finished (14): * SSLv3, TLS handshake, Client key exchange (16): * SSLv3, TLS change cipher, Client hello (1): * SSLv3, TLS handshake, Finished (20): * SSLv3, TLS change cipher, Client hello (1): * SSLv3, TLS handshake, Finished (20): * SSL connection using TLSv1.2 / ECDHE-ECDSA-AES256-GCM-SHA384 * Server certificate: * subject: CN=p***r.app * start date: 2019-03-05 22:08:00 GMT * expire date: 2019-06-03 22:08:00 GMT * subjectAltName: p***r.app matched * issuer: C=US; O=Let's Encrypt; CN=Let's Encrypt Authority X3 * SSL certificate verify ok. > OPTIONS /wp-json/wc/v2/products/categories?consumer_key=ck_3***2 HTTP/1.1 > User-Agent: curl/7.38.0 > Host: p***r.app > Accept: */* > Origin: http://localhost:8080 > Access-Control-Request-Method: POST > Access-Control-Request-Headers: X-Requested-With > < HTTP/1.1 200 OK < Date: Thu, 11 Apr 2019 00:09:42 GMT * Server Apache is not blacklisted < Server: Apache < X-Powered-By: PHP/7.0.31 < X-Robots-Tag: noindex < Link: <https://p***r.app/wp-json/>; rel="https://api.w.org/" < X-Content-Type-Options: nosniff < Access-Control-Expose-Headers: X-WP-Total, X-WP-TotalPages < Access-Control-Allow-Headers: Authorization, Content-Type < Cache-Control: public, max-age=2592000 < Access-Control-Allow-Origin: http://localhost:8080 < Access-Control-Allow-Methods: OPTIONS, GET, POST, PUT, PATCH, DELETE < Access-Control-Allow-Credentials: true < Vary: Origin < X-Frame-Options: SAMEORIGIN < Transfer-Encoding: chunked < Content-Type: application/json; charset=UTF-8
Posts: 1
Participants: 1