forked frompostgres/postgres
- Notifications
You must be signed in to change notification settings - Fork6
Commit891e6e7
committed
Require execute permission on the trigger function for CREATE TRIGGER.
This check was overlooked when we added function execute permissions to thesystem years ago. For an ordinary trigger function it's not a big deal,since trigger functions execute with the permissions of the table owner,so they couldn't do anything the user issuing the CREATE TRIGGER couldn'thave done anyway. However, if a trigger function is SECURITY DEFINER,that is not the case. The lack of checking would allow another user toinstall it on his own table and then invoke it with, essentially, forgedinput data; which the trigger function is unlikely to realize, so it mightdo something undesirable, for instance insert false entries in an audit logtable.Reported by Dinesh Kumar, patch by Robert HaasSecurity:CVE-2012-08661 parent74e2916 commit891e6e7
File tree
2 files changed
+11
-3
lines changed- doc/src/sgml/ref
- src/backend/commands
2 files changed
+11
-3
lines changedLines changed: 2 additions & 1 deletion
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
362 | 362 |
| |
363 | 363 |
| |
364 | 364 |
| |
365 |
| - | |
| 365 | + | |
| 366 | + | |
366 | 367 |
| |
367 | 368 |
| |
368 | 369 |
| |
|
Lines changed: 9 additions & 2 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
108 | 108 |
| |
109 | 109 |
| |
110 | 110 |
| |
111 |
| - | |
112 |
| - | |
| 111 | + | |
| 112 | + | |
113 | 113 |
| |
114 | 114 |
| |
115 | 115 |
| |
| |||
377 | 377 |
| |
378 | 378 |
| |
379 | 379 |
| |
| 380 | + | |
| 381 | + | |
| 382 | + | |
| 383 | + | |
| 384 | + | |
| 385 | + | |
| 386 | + | |
380 | 387 |
| |
381 | 388 |
| |
382 | 389 |
| |
|
0 commit comments
Comments
(0)