- Notifications
You must be signed in to change notification settings - Fork28
Commit3804e89
committed
Prohibit transaction commands in security definer procedures
Starting and aborting transactions in security definer proceduresdoesn't work. StartTransaction() insists that the security contextstack is empty, so this would currently cause a crash, andAbortTransaction() resets it. This could be made to work byreorganizing the code, but right now we just prohibit it.Reported-by: amul sul <sulamul@gmail.com>Discussion:https://www.postgresql.org/message-id/flat/CAAJ_b96Gupt_LFL7uNyy3c50-wbhA68NUjiK5%3DrF6_w%3Dpq_T%3DQ%40mail.gmail.com1 parent39035a5 commit3804e89
File tree
4 files changed
+40
-0
lines changed- doc/src/sgml/ref
- src
- backend/commands
- pl/plpgsql/src
- expected
- sql
4 files changed
+40
-0
lines changedLines changed: 6 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
203 | 203 |
| |
204 | 204 |
| |
205 | 205 |
| |
| 206 | + | |
| 207 | + | |
| 208 | + | |
| 209 | + | |
| 210 | + | |
| 211 | + | |
206 | 212 |
| |
207 | 213 |
| |
208 | 214 |
| |
|
Lines changed: 9 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
2245 | 2245 |
| |
2246 | 2246 |
| |
2247 | 2247 |
| |
| 2248 | + | |
| 2249 | + | |
| 2250 | + | |
| 2251 | + | |
| 2252 | + | |
| 2253 | + | |
| 2254 | + | |
| 2255 | + | |
| 2256 | + | |
2248 | 2257 |
| |
2249 | 2258 |
| |
2250 | 2259 |
| |
|
Lines changed: 12 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
130 | 130 |
| |
131 | 131 |
| |
132 | 132 |
| |
| 133 | + | |
| 134 | + | |
| 135 | + | |
| 136 | + | |
| 137 | + | |
| 138 | + | |
| 139 | + | |
| 140 | + | |
| 141 | + | |
| 142 | + | |
| 143 | + | |
| 144 | + | |
133 | 145 |
| |
134 | 146 |
| |
135 | 147 |
| |
|
Lines changed: 13 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
116 | 116 |
| |
117 | 117 |
| |
118 | 118 |
| |
| 119 | + | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
| 123 | + | |
| 124 | + | |
| 125 | + | |
| 126 | + | |
| 127 | + | |
| 128 | + | |
| 129 | + | |
| 130 | + | |
| 131 | + | |
119 | 132 |
| |
120 | 133 |
| |
121 | 134 |
| |
|
0 commit comments
Comments
(0)