forked frompostgres/postgres
- Notifications
You must be signed in to change notification settings - Fork6
Commitbd029bc
committed
From: Tom Lane <tgl@sss.pgh.pa.us>The attached patches respond to discussion that was on pgsql-hackersaround the beginning of June (see thread "libpgtcl bug (and symptomatictreatment)"). The changes are:1. Remove code in connectDB that throws away the password after makinga connection. This doesn't really add much security IMHO --- a bad guywith access to your client's address space can likely extract thepassword anyway, to say nothing of what he might do directly. Andthere's the serious shortcoming that it prevents PQreset() from workingif the database requires a password.2. Fix coredump problem: fe_sendauth did not guard against being handeda NULL password pointer. (This is the proximate cause of the coredump-during-PQreset problem that Magosanyi Arpad complained of last month.)3. Remove highly questionable "error recovery" logic in libpgtcl'spg_exec statement.I believe the consensus of the discussion last month was in favor of#1 and#3, but I'm just now getting around to making the change.I realized that#2 was a bug in process of looking at the change.
1 parentce81267 commitbd029bc
File tree
3 files changed
+10
-32
lines changed- src/interfaces
- libpgtcl
- libpq
3 files changed
+10
-32
lines changedLines changed: 2 additions & 19 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
7 | 7 |
| |
8 | 8 |
| |
9 | 9 |
| |
10 |
| - | |
| 10 | + | |
11 | 11 |
| |
12 | 12 |
| |
13 | 13 |
| |
| |||
441 | 441 |
| |
442 | 442 |
| |
443 | 443 |
| |
444 |
| - | |
445 |
| - | |
446 |
| - | |
447 |
| - | |
448 |
| - | |
449 |
| - | |
450 |
| - | |
451 |
| - | |
452 |
| - | |
453 |
| - | |
454 |
| - | |
455 |
| - | |
456 |
| - | |
457 |
| - | |
458 |
| - | |
459 |
| - | |
460 |
| - | |
461 |
| - | |
| 444 | + | |
462 | 445 |
| |
463 | 446 |
| |
464 | 447 |
| |
|
Lines changed: 7 additions & 1 deletion
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
7 | 7 |
| |
8 | 8 |
| |
9 | 9 |
| |
10 |
| - | |
| 10 | + | |
11 | 11 |
| |
12 | 12 |
| |
13 | 13 |
| |
| |||
522 | 522 |
| |
523 | 523 |
| |
524 | 524 |
| |
| 525 | + | |
| 526 | + | |
| 527 | + | |
| 528 | + | |
| 529 | + | |
| 530 | + | |
525 | 531 |
| |
526 | 532 |
| |
527 | 533 |
| |
|
Lines changed: 1 addition & 12 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
7 | 7 |
| |
8 | 8 |
| |
9 | 9 |
| |
10 |
| - | |
| 10 | + | |
11 | 11 |
| |
12 | 12 |
| |
13 | 13 |
| |
| |||
768 | 768 |
| |
769 | 769 |
| |
770 | 770 |
| |
771 |
| - | |
772 |
| - | |
773 |
| - | |
774 |
| - | |
775 |
| - | |
776 |
| - | |
777 |
| - | |
778 |
| - | |
779 |
| - | |
780 |
| - | |
781 |
| - | |
782 | 771 |
| |
783 | 772 |
| |
784 | 773 |
| |
|
0 commit comments
Comments
(0)