Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added an option to skip ssl validation #228

Merged
merged 3 commits into from
Apr 18, 2022
Merged

Added an option to skip ssl validation #228

merged 3 commits into from
Apr 18, 2022

Conversation

tomer-cohen
Copy link
Contributor

As mentioned in this issue:
#82

This check for the DangerousAcceptAnyServerCertificateValidator flag in the route settings, if it's set to true - the ssl certificate validation will be skipped when trying to retrieve swagger.json.

@update-docs
Copy link

update-docs bot commented Apr 13, 2022

Thanks for opening this pull request! If you have implemented new functions, write about them in the readme file.

Copy link
Owner

@Burgyn Burgyn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi,
thanks for your PR. Please fix CodeFactor issue and my single comment.

@tomer-cohen tomer-cohen requested a review from Burgyn April 18, 2022 07:41
@Burgyn Burgyn merged commit 0cc6cad into Burgyn:master Apr 18, 2022
@Burgyn
Copy link
Owner

Burgyn commented Apr 18, 2022

Hi, thanks. This will be released as version 5.1.0 in a few minutes.

@tomer-cohen tomer-cohen deleted the SkipSslCertificateValidationOption branch April 18, 2022 09:32
@AndryKwiatow
Copy link

AndryKwiatow commented Apr 21, 2022

Hey guys, I saw this and was wondering: is this intended to be used this way? (See example below)

"Config": [
        {
          "DangerousAcceptAnyServerCertificateValidator": true,
          "Name": "Shipping API",
          "Version": "v1",
          "Url": "https://localhost:7020/swagger/v1/swagger.json"
        }
      ]

@Burgyn
Copy link
Owner

Burgyn commented Apr 21, 2022

Hi @AndryKwiatow,

No. Property DangerousAcceptAnyServerCertificateValidator should be set in the route configuration.
E.g.:

 "Routes": [
   {
     "DownstreamPathTemplate": "/api/{everything}",
     "DownstreamHostAndPorts": [
       {
          "Host": "localhost",
          "Port": 5100
       }
     ],
     "UpstreamPathTemplate": "/api/contacts/{everything}",
     "SwaggerKey": "contacts",
     "DangerousAcceptAnyServerCertificateValidator": true
   }
]

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants