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

*: use https protocol between tidb-pd tidb-tidb when cluster-ssl configured #15342

Merged
merged 2 commits into from
Mar 16, 2020
Merged

*: use https protocol between tidb-pd tidb-tidb when cluster-ssl configured #15342

merged 2 commits into from
Mar 16, 2020

Conversation

lysu
Copy link
Contributor

@lysu lysu commented Mar 12, 2020

What problem does this PR solve?

fixes #15120

PD or TiDB RESTful service will require https when cluster configured with cluster-ssl-*, but tidb-server only can send http request.

What is changed and how it works?

change to https client when "cluster-ssl-*" configured

Check List

Tests

  • Manual test

configure pd/tidb/tikv as https://pingcap.com/docs/stable/how-to/secure/enable-tls-between-components/

then try to use TiDB http-api or "cluster table"

Code changes

  • replace all http to http/https
  • use https client when "cluster-ssl-*" configured

Side effects

  • n/a

Related changes

  • Need to cherry-pick to the release branch
    Release note

  • use https request between tidb-pd tidb-tidb when cluster-ssl configured.


This change is Reviewable

@lysu lysu added component/server security Everything related with security labels Mar 12, 2020
@lysu lysu requested a review from a team as a code owner March 12, 2020 12:48
@ghost ghost requested review from qw4990 and XuHuaiyu and removed request for a team March 12, 2020 12:48
@lysu
Copy link
Contributor Author

lysu commented Mar 12, 2020

/run-all-tests

@lysu lysu requested review from imtbkcat and jackysp March 12, 2020 12:48
@lysu lysu changed the title *: use https request between tidb-pd tidb-tidb when cluster-ssl configured *: use https protocol between tidb-pd tidb-tidb when cluster-ssl configured Mar 12, 2020
@lysu lysu removed request for qw4990 and XuHuaiyu March 12, 2020 12:49
@github-actions github-actions bot added sig/sql-infra SIG: SQL Infra sig/execution SIG execution labels Mar 12, 2020
@lysu
Copy link
Contributor Author

lysu commented Mar 12, 2020

/run-unit-test

@codecov
Copy link

codecov bot commented Mar 12, 2020

Codecov Report

Merging #15342 into master will decrease coverage by 0.1138%.
The diff coverage is 67.4418%.

@@               Coverage Diff                @@
##             master     #15342        +/-   ##
================================================
- Coverage   80.4736%   80.3598%   -0.1139%     
================================================
  Files           502        502                
  Lines        133676     133242       -434     
================================================
- Hits         107574     107073       -501     
- Misses        17685      17753        +68     
+ Partials       8417       8416         -1

Copy link
Member

@jackysp jackysp left a comment

Choose a reason for hiding this comment

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

LGTM

Copy link

@imtbkcat imtbkcat left a comment

Choose a reason for hiding this comment

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

LGTM

@jackysp
Copy link
Member

jackysp commented Mar 16, 2020

/merge

@sre-bot sre-bot added the status/can-merge Indicates a PR has been approved by a committer. label Mar 16, 2020
@sre-bot
Copy link
Contributor

sre-bot commented Mar 16, 2020

/run-all-tests

@sre-bot sre-bot merged commit a977875 into pingcap:master Mar 16, 2020
@lysu lysu deleted the dev-http-client-tls branch March 17, 2020 06:18
@lysu
Copy link
Contributor Author

lysu commented Mar 17, 2020

/run-cherry-picker

@sre-bot
Copy link
Contributor

sre-bot commented Mar 17, 2020

cherry pick to release-3.0 in PR #15419

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component/server security Everything related with security sig/execution SIG execution status/can-merge Indicates a PR has been approved by a committer.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

can't select CLUSTER_INFO table when TLS between server components is enabled
4 participants