René's URL Explorer Experiment


Title: error javax.net.ssl.SSLHandshakeException: · Issue #33 · nativescript-community/https · GitHub

Open Graph Title: error javax.net.ssl.SSLHandshakeException: · Issue #33 · nativescript-community/https

X Title: error javax.net.ssl.SSLHandshakeException: · Issue #33 · nativescript-community/https

Description: I need really your support. I have a big problem that I don't understand why happens. I used this plugin because I want to communicate with protocol https. So, Firstly I install this plugin, and write in component.ts this code: enableSSL...

Open Graph Description: I need really your support. I have a big problem that I don't understand why happens. I used this plugin because I want to communicate with protocol https. So, Firstly I install this plugin, and wr...

X Description: I need really your support. I have a big problem that I don't understand why happens. I used this plugin because I want to communicate with protocol https. So, Firstly I install this plugin, an...

Opengraph URL: https://github.com/nativescript-community/https/issues/33

X: @github

direct link

Domain: patch-diff.githubusercontent.com


Hey, it has json ld scripts:
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"error javax.net.ssl.SSLHandshakeException:","articleBody":"I need really your support.\r\n\r\nI have a big problem that I don't understand why happens.\r\n\r\nI used this plugin because I want to communicate with protocol https.\r\n\r\nSo, Firstly I install this plugin, and write in component.ts this code:\r\n\r\n    enableSSLpinning() {\r\n        let certificate: any;\r\n        Https.enableSSLPinning({ host: 'xx.xxx.xx.xx:3333', certificate, allowInvalidCertificates: true, validatesDomainName: false })\r\n        Https.request({\r\n            url: 'https://xx.xxx.xx.xx:3333/user',\r\n            method: 'GET',\r\n            headers: {\r\n                \"Content-type\": \"application/x-www-form-urlencoded\",\r\n            },\r\n        }).then(function (response) {\r\n            console.log('Https.request response', response);\r\n        }).catch(function (error) {\r\n            console.error('Https.request error', error);\r\n        })\r\n    }\r\n\r\n\r\n\r\nin https.android.js I modify only certificate in this part:\r\n      \r\n\r\n      function enableSSLPinning(options) {\r\n             if (!peer.host \u0026\u0026 !peer.certificate\r\n                   ) {\r\n                   var certificate = void 0;\r\n                 var InputSteram = void 0;\r\n        try {\r\n            var inputStream = new java.io.ByteArrayInputStream(new java.lang.String(\"-----BEGIN CERTIFICATE-----\\n\"\r\n                + \"MIIFjDCCA3SgAwIBAgIJAMOXpEn+QQSVMA0GCSqGSIb3DQEBCwUAMIGBMQswCQYD\\n\"\r\n                + \"VQQGEwJVUzELMAkGA1UECAwCTUExDzANBgNVBAcMBkJvc3RvbjETMBEGA1UECgwK\\n\"\r\n                  ..................\r\n                + \"1AYJwo2yFqmetdmOYaFh6Cli8OerUERDqPB1UKPmYQE=\\n\"\r\n                + \"-----END CERTIFICATE-----\").getBytes(\"UTF-8\"));\r\n            var x509Certificate = java.security.cert.CertificateFactory.getInstance('X.509').generateCertificate(inputStream);\r\n            peer.x509Certificate = x509Certificate;\r\n            certificate = okhttp3.CertificatePinner.pin(x509Certificate);\r\n            inputStream.close();\r\n            }\r\n        catch (error) {\r\n            try {\r\n                if (inputStream) {\r\n                    console.log('inputStream', inputStream)\r\n                    inputStream.close();\r\n                }\r\n            }\r\n            catch (e) { }\r\n            console.error('nativescript-https \u003e enableSSLPinning error', error);\r\n            return;\r\n        }\r\n        peer.host = options.host;\r\n        peer.certificate = certificate;\r\n        if (options.allowInvalidCertificates == true) {\r\n            peer.allowInvalidCertificates = true;\r\n        }\r\n        if (options.validatesDomainName == false) {\r\n            peer.validatesDomainName = false;\r\n        }\r\n    }\r\n    peer.enabled = true;\r\n    getClient(true);\r\n    console.log('nativescript-https \u003e Enabled SSL pinning');\r\n}\r\n\r\nThis parts execute correct, in console print `'nativescript-https \u003e Enabled SSL pinning'`\r\n\r\nError show in this part:  `console.error('Https.request error', error);`\r\n\r\n\u003e JS: Https.request error javax.net.ssl.SSLHandshakeException:\r\n\u003e java.security.cert.CertPathValidatorException: Trust anchor for\r\n\u003e certification path not found.\r\n\r\nAnd in `https.android.js` call this  function\r\n\r\n    function request(opts) {\r\n        console.log('opts', opts)\r\n        return new Promise(function (resolve, reject) {\r\n            try {\r\n                var client = getClient();\r\n                var request_1 = new okhttp3.Request.Builder();\r\n                request_1.url(opts.url);\r\n                var reqheads_1 = opts.headers;\r\n                Object.keys(reqheads_1).forEach(function (key) {\r\n                    request_1.addHeader(key, reqheads_1[key]);\r\n                });\r\n                if (opts.method == 'GET') {\r\n                    request_1.get();\r\n                }\r\n                else if (opts.method == 'POST') {\r\n                    var type = okhttp3.MediaType.parse('application/json');\r\n                    var body = okhttp3.RequestBody.create(type, opts.content);\r\n                    request_1.post(body);\r\n                }\r\n                client.newCall(request_1.build()).enqueue(new okhttp3.Callback({\r\n                    onResponse: function (task, response) {\r\n                        var content;\r\n                        try {\r\n                            content = JSON.parse(response.body().string());\r\n                        }\r\n                        catch (error) {\r\n                            return reject(error);\r\n                        }\r\n                        var statusCode = response.code();\r\n                        var headers = {};\r\n                        var heads = response.headers();\r\n                        var i, len = heads.size();\r\n                        for (i = 0; i \u003c len; i++) {\r\n                            var key = heads.name(i);\r\n                            var value = heads.value(i);\r\n                            headers[key] = value;\r\n                        }\r\n                        resolve({ content: content, statusCode: statusCode, headers: headers });\r\n                    },\r\n                    onFailure: function (task, error) {\r\n                        reject(error);\r\n                    },\r\n                }));\r\n            }\r\n            catch (error) {\r\n                reject(error);\r\n            }\r\n        });\r\n    }\r\n\r\n\r\nPlease, can you ask me any idea, which is the problem in my code? Thank you\r\n\r\nThanks!\r\n\r\nUpdate:\r\n\r\nI think that a problem is in this part of code:\r\n\r\n      onResponse: function (task, response) {\r\n                console.load('testfdsfsdfsdfsd')\r\n                var content;\r\n                console.log('content', content)\r\n                try {\r\n                    content = JSON.parse(response.body().string());\r\n                    console.log('content1', content)\r\n                }\r\n                catch (error) {\r\n                    console.log('error111111', error)\r\n                    return reject(error);\r\n                }\r\n                var statusCode = response.code();\r\n                var headers = {};\r\n                var heads = response.headers();\r\n                var i, len = heads.size();\r\n                for (i = 0; i \u003c len; i++) {\r\n                    var key = heads.name(i);\r\n                    var value = heads.value(i);\r\n                    headers[key] = value;\r\n                }\r\n                resolve({ content: content, statusCode: statusCode, headers: headers });\r\n            },\r\n\r\nbecause this part is not executed, it passes directly to onFailure\r\n\r\n  \r\n\r\n    onFailure: function (task, error) {\r\n                    reject(error);\r\n                },","author":{"url":"https://github.com/2adi","@type":"Person","name":"2adi"},"datePublished":"2018-08-15T15:20:08.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":0},"url":"https://github.com/33/https/issues/33"}

route-pattern/_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format)
route-controllervoltron_issues_fragments
route-actionissue_layout
fetch-noncev2:90eb7cb4-3b4f-7276-2759-3698bfe5922a
current-catalog-service-hash81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114
request-id9270:7F630:25E3E7E:34161A7:698CE70F
html-safe-nonce4e0d9189ed8d3fb4182a66d5ed17fadbbc146562473b2444a62f94a608677107
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI5MjcwOjdGNjMwOjI1RTNFN0U6MzQxNjFBNzo2OThDRTcwRiIsInZpc2l0b3JfaWQiOiI3Mzk3ODAzNjI0MDQ5MjA3MDU1IiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0=
visitor-hmaca0d59859878b0f54cf2d18d6f9abff607892b2bca5117d93d34dd201360a9351
hovercard-subject-tagissue:350850856
github-keyboard-shortcutsrepository,issues,copilot
google-site-verificationApib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I
octolytics-urlhttps://collector.github.com/github/collect
analytics-location///voltron/issues_fragments/issue_layout
fb:app_id1401488693436528
apple-itunes-appapp-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/nativescript-community/https/33/issue_layout
twitter:imagehttps://opengraph.githubassets.com/b9c93bb42faed132fcb6d7554595330454265f434f75d02b104ccfe47bff2d61/nativescript-community/https/issues/33
twitter:cardsummary_large_image
og:imagehttps://opengraph.githubassets.com/b9c93bb42faed132fcb6d7554595330454265f434f75d02b104ccfe47bff2d61/nativescript-community/https/issues/33
og:image:altI need really your support. I have a big problem that I don't understand why happens. I used this plugin because I want to communicate with protocol https. So, Firstly I install this plugin, and wr...
og:image:width1200
og:image:height600
og:site_nameGitHub
og:typeobject
og:author:username2adi
hostnamegithub.com
expected-hostnamegithub.com
None640eeb7b6ff4d8d106235d228c0c286e82592d4d2403227b5b2b4fc5832297a4
turbo-cache-controlno-preview
go-importgithub.com/nativescript-community/https git https://github.com/nativescript-community/https.git
octolytics-dimension-user_id50633791
octolytics-dimension-user_loginnativescript-community
octolytics-dimension-repository_id77530217
octolytics-dimension-repository_nwonativescript-community/https
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forkfalse
octolytics-dimension-repository_network_root_id77530217
octolytics-dimension-repository_network_root_nwonativescript-community/https
turbo-body-classeslogged-out env-production page-responsive
disable-turbofalse
browser-stats-urlhttps://api.github.com/_private/browser/stats
browser-errors-urlhttps://api.github.com/_private/browser/errors
release3d444f0a47beeeac94cddbb51c91ab408befe8d4
ui-targetfull
theme-color#1e2327
color-schemelight dark

Links:

Skip to contenthttps://patch-diff.githubusercontent.com/nativescript-community/https/issues/33#start-of-content
https://patch-diff.githubusercontent.com/
Sign in https://patch-diff.githubusercontent.com/login?return_to=https%3A%2F%2Fgithub.com%2Fnativescript-community%2Fhttps%2Fissues%2F33
GitHub CopilotWrite better code with AIhttps://github.com/features/copilot
GitHub SparkBuild and deploy intelligent appshttps://github.com/features/spark
GitHub ModelsManage and compare promptshttps://github.com/features/models
MCP RegistryNewIntegrate external toolshttps://github.com/mcp
ActionsAutomate any workflowhttps://github.com/features/actions
CodespacesInstant dev environmentshttps://github.com/features/codespaces
IssuesPlan and track workhttps://github.com/features/issues
Code ReviewManage code changeshttps://github.com/features/code-review
GitHub Advanced SecurityFind and fix vulnerabilitieshttps://github.com/security/advanced-security
Code securitySecure your code as you buildhttps://github.com/security/advanced-security/code-security
Secret protectionStop leaks before they starthttps://github.com/security/advanced-security/secret-protection
Why GitHubhttps://github.com/why-github
Documentationhttps://docs.github.com
Bloghttps://github.blog
Changeloghttps://github.blog/changelog
Marketplacehttps://github.com/marketplace
View all featureshttps://github.com/features
Enterpriseshttps://github.com/enterprise
Small and medium teamshttps://github.com/team
Startupshttps://github.com/enterprise/startups
Nonprofitshttps://github.com/solutions/industry/nonprofits
App Modernizationhttps://github.com/solutions/use-case/app-modernization
DevSecOpshttps://github.com/solutions/use-case/devsecops
DevOpshttps://github.com/solutions/use-case/devops
CI/CDhttps://github.com/solutions/use-case/ci-cd
View all use caseshttps://github.com/solutions/use-case
Healthcarehttps://github.com/solutions/industry/healthcare
Financial serviceshttps://github.com/solutions/industry/financial-services
Manufacturinghttps://github.com/solutions/industry/manufacturing
Governmenthttps://github.com/solutions/industry/government
View all industrieshttps://github.com/solutions/industry
View all solutionshttps://github.com/solutions
AIhttps://github.com/resources/articles?topic=ai
Software Developmenthttps://github.com/resources/articles?topic=software-development
DevOpshttps://github.com/resources/articles?topic=devops
Securityhttps://github.com/resources/articles?topic=security
View all topicshttps://github.com/resources/articles
Customer storieshttps://github.com/customer-stories
Events & webinarshttps://github.com/resources/events
Ebooks & reportshttps://github.com/resources/whitepapers
Business insightshttps://github.com/solutions/executive-insights
GitHub Skillshttps://skills.github.com
Documentationhttps://docs.github.com
Customer supporthttps://support.github.com
Community forumhttps://github.com/orgs/community/discussions
Trust centerhttps://github.com/trust-center
Partnershttps://github.com/partners
GitHub SponsorsFund open source developershttps://github.com/sponsors
Security Labhttps://securitylab.github.com
Maintainer Communityhttps://maintainers.github.com
Acceleratorhttps://github.com/accelerator
Archive Programhttps://archiveprogram.github.com
Topicshttps://github.com/topics
Trendinghttps://github.com/trending
Collectionshttps://github.com/collections
Enterprise platformAI-powered developer platformhttps://github.com/enterprise
GitHub Advanced SecurityEnterprise-grade security featureshttps://github.com/security/advanced-security
Copilot for BusinessEnterprise-grade AI featureshttps://github.com/features/copilot/copilot-business
Premium SupportEnterprise-grade 24/7 supporthttps://github.com/premium-support
Pricinghttps://github.com/pricing
Search syntax tipshttps://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax
documentationhttps://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax
Sign in https://patch-diff.githubusercontent.com/login?return_to=https%3A%2F%2Fgithub.com%2Fnativescript-community%2Fhttps%2Fissues%2F33
Sign up https://patch-diff.githubusercontent.com/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-name%3E%2F%3Crepo-name%3E%2Fvoltron%2Fissues_fragments%2Fissue_layout&source=header-repo&source_repo=nativescript-community%2Fhttps
Reloadhttps://patch-diff.githubusercontent.com/nativescript-community/https/issues/33
Reloadhttps://patch-diff.githubusercontent.com/nativescript-community/https/issues/33
Reloadhttps://patch-diff.githubusercontent.com/nativescript-community/https/issues/33
nativescript-community https://patch-diff.githubusercontent.com/nativescript-community
httpshttps://patch-diff.githubusercontent.com/nativescript-community/https
Please reload this pagehttps://patch-diff.githubusercontent.com/nativescript-community/https/issues/33
Notifications https://patch-diff.githubusercontent.com/login?return_to=%2Fnativescript-community%2Fhttps
Fork 40 https://patch-diff.githubusercontent.com/login?return_to=%2Fnativescript-community%2Fhttps
Star 51 https://patch-diff.githubusercontent.com/login?return_to=%2Fnativescript-community%2Fhttps
Code https://patch-diff.githubusercontent.com/nativescript-community/https
Issues 13 https://patch-diff.githubusercontent.com/nativescript-community/https/issues
Pull requests 1 https://patch-diff.githubusercontent.com/nativescript-community/https/pulls
Actions https://patch-diff.githubusercontent.com/nativescript-community/https/actions
Projects 0 https://patch-diff.githubusercontent.com/nativescript-community/https/projects
Security 0 https://patch-diff.githubusercontent.com/nativescript-community/https/security
Insights https://patch-diff.githubusercontent.com/nativescript-community/https/pulse
Code https://patch-diff.githubusercontent.com/nativescript-community/https
Issues https://patch-diff.githubusercontent.com/nativescript-community/https/issues
Pull requests https://patch-diff.githubusercontent.com/nativescript-community/https/pulls
Actions https://patch-diff.githubusercontent.com/nativescript-community/https/actions
Projects https://patch-diff.githubusercontent.com/nativescript-community/https/projects
Security https://patch-diff.githubusercontent.com/nativescript-community/https/security
Insights https://patch-diff.githubusercontent.com/nativescript-community/https/pulse
New issuehttps://patch-diff.githubusercontent.com/login?return_to=https://github.com/nativescript-community/https/issues/33
New issuehttps://patch-diff.githubusercontent.com/login?return_to=https://github.com/nativescript-community/https/issues/33
error javax.net.ssl.SSLHandshakeException:https://patch-diff.githubusercontent.com/nativescript-community/https/issues/33#top
https://github.com/2adi
https://github.com/2adi
2adihttps://github.com/2adi
on Aug 15, 2018https://github.com/nativescript-community/https/issues/33#issue-350850856
https://github.com
Termshttps://docs.github.com/site-policy/github-terms/github-terms-of-service
Privacyhttps://docs.github.com/site-policy/privacy-policies/github-privacy-statement
Securityhttps://github.com/security
Statushttps://www.githubstatus.com/
Communityhttps://github.community/
Docshttps://docs.github.com/
Contacthttps://support.github.com?tags=dotcom-footer

Viewport: width=device-width


URLs of crawlers that visited me.