- Notifications
You must be signed in to change notification settings - Fork4.9k
Commit680513a
committed
Break out OpenSSL-specific code to separate files.
This refactoring is in preparation for adding support for other SSLimplementations, with no user-visible effects. There are now two #defines,USE_OPENSSL which is defined when building with OpenSSL, and USE_SSL whichis defined when building with any SSL implementation. Currently, OpenSSL isthe only implementation so the two #defines go together, but USE_SSL issupposed to be used for implementation-independent code.The libpq SSL code is changed to use a custom BIO, which does all the rawI/O, like we've been doing in the backend for a long time. That makes itpossible to use MSG_NOSIGNAL to block SIGPIPE when using SSL, which avoidsa couple of syscall for each send(). Probably doesn't make much performancedifference in practice - the SSL encryption is expensive enough to mask theeffect - but it was a natural result of this refactoring.Based on a patch by Martijn van Oosterhout from 2006. Briefly reviewed byAlvaro Herrera, Andreas Karlsson, Jeff Janes.1 parent6aa6158 commit680513a
File tree
26 files changed
+2771
-2417
lines changed- src
- backend
- libpq
- postmaster
- utils
- init
- misc
- bin/psql
- include
- libpq
- interfaces/libpq
- tools/msvc
26 files changed
+2771
-2417
lines changedLines changed: 1 addition & 1 deletion
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
5492 | 5492 |
| |
5493 | 5493 |
| |
5494 | 5494 |
| |
5495 |
| - | |
| 5495 | + | |
5496 | 5496 |
| |
5497 | 5497 |
| |
5498 | 5498 |
| |
|
Lines changed: 1 addition & 1 deletion
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
657 | 657 |
| |
658 | 658 |
| |
659 | 659 |
| |
660 |
| - | |
| 660 | + | |
661 | 661 |
| |
662 | 662 |
| |
663 | 663 |
| |
|
Lines changed: 4 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
17 | 17 |
| |
18 | 18 |
| |
19 | 19 |
| |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
20 | 24 |
|
Lines changed: 7 additions & 7 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
161 | 161 |
| |
162 | 162 |
| |
163 | 163 |
| |
164 |
| - | |
| 164 | + | |
165 | 165 |
| |
166 | 166 |
| |
167 | 167 |
| |
| |||
330 | 330 |
| |
331 | 331 |
| |
332 | 332 |
| |
333 |
| - | |
| 333 | + | |
334 | 334 |
| |
335 | 335 |
| |
336 | 336 |
| |
| |||
378 | 378 |
| |
379 | 379 |
| |
380 | 380 |
| |
381 |
| - | |
| 381 | + | |
382 | 382 |
| |
383 | 383 |
| |
384 | 384 |
| |
| |||
394 | 394 |
| |
395 | 395 |
| |
396 | 396 |
| |
397 |
| - | |
| 397 | + | |
398 | 398 |
| |
399 | 399 |
| |
400 | 400 |
| |
| |||
452 | 452 |
| |
453 | 453 |
| |
454 | 454 |
| |
455 |
| - | |
| 455 | + | |
456 | 456 |
| |
457 | 457 |
| |
458 | 458 |
| |
| |||
470 | 470 |
| |
471 | 471 |
| |
472 | 472 |
| |
473 |
| - | |
| 473 | + | |
474 | 474 |
| |
475 | 475 |
| |
476 | 476 |
| |
| |||
2315 | 2315 |
| |
2316 | 2316 |
| |
2317 | 2317 |
| |
2318 |
| - | |
| 2318 | + | |
2319 | 2319 |
| |
2320 | 2320 |
| |
2321 | 2321 |
| |
|
0 commit comments
Comments
(0)