- Notifications
You must be signed in to change notification settings - Fork5
Commit22eaf35
committed
RLS refactoring
This refactors rewrite/rowsecurity.c to simplify the handling of thedefault deny case (reducing the number of places where we check for andadd the default deny policy from three to one) by splitting up theretrival of the policies from the application of them.This also allowed us to do away with the policy_id field. A policy_namefield was added for WithCheckOption policies and is used in errorreporting, when available.Patch by Dean Rasheed, with various mostly cosmetic changes by me.Back-patch to 9.5 where RLS was introduced to avoid unnecessarydifferences, since we're still in alpha, per discussion with Robert.1 parent000a213 commit22eaf35
File tree
13 files changed
+447
-457
lines changed- src
- backend
- commands
- executor
- nodes
- rewrite
- utils/cache
- include
- nodes
- rewrite
- test/modules/test_rls_hooks
- expected
13 files changed
+447
-457
lines changedLines changed: 0 additions & 41 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
186 | 186 |
| |
187 | 187 |
| |
188 | 188 |
| |
189 |
| - | |
190 |
| - | |
191 |
| - | |
192 | 189 |
| |
193 | 190 |
| |
194 | 191 |
| |
| |||
246 | 243 |
| |
247 | 244 |
| |
248 | 245 |
| |
249 |
| - | |
250 | 246 |
| |
251 | 247 |
| |
252 | 248 |
| |
| |||
298 | 294 |
| |
299 | 295 |
| |
300 | 296 |
| |
301 |
| - | |
302 |
| - | |
303 | 297 |
| |
304 | 298 |
| |
305 | 299 |
| |
306 | 300 |
| |
307 | 301 |
| |
308 |
| - | |
309 | 302 |
| |
310 | 303 |
| |
311 | 304 |
| |
| |||
326 | 319 |
| |
327 | 320 |
| |
328 | 321 |
| |
329 |
| - | |
330 |
| - | |
331 |
| - | |
332 |
| - | |
333 |
| - | |
334 |
| - | |
335 |
| - | |
336 |
| - | |
337 |
| - | |
338 |
| - | |
339 |
| - | |
340 |
| - | |
341 |
| - | |
342 |
| - | |
343 |
| - | |
344 |
| - | |
345 |
| - | |
346 |
| - | |
347 |
| - | |
348 |
| - | |
349 |
| - | |
350 |
| - | |
351 |
| - | |
352 |
| - | |
353 |
| - | |
354 |
| - | |
355 |
| - | |
356 |
| - | |
357 |
| - | |
358 |
| - | |
359 |
| - | |
360 |
| - | |
361 |
| - | |
362 |
| - | |
363 | 322 |
| |
364 | 323 |
| |
365 | 324 |
| |
|
Lines changed: 16 additions & 4 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
1815 | 1815 |
| |
1816 | 1816 |
| |
1817 | 1817 |
| |
1818 |
| - | |
1819 |
| - | |
| 1818 | + | |
| 1819 | + | |
| 1820 | + | |
| 1821 | + | |
| 1822 | + | |
| 1823 | + | |
| 1824 | + | |
| 1825 | + | |
1820 | 1826 |
| |
1821 | 1827 |
| |
1822 | 1828 |
| |
1823 | 1829 |
| |
1824 |
| - | |
1825 |
| - | |
| 1830 | + | |
| 1831 | + | |
| 1832 | + | |
| 1833 | + | |
| 1834 | + | |
| 1835 | + | |
| 1836 | + | |
| 1837 | + | |
1826 | 1838 |
| |
1827 | 1839 |
| |
1828 | 1840 |
| |
|
Lines changed: 1 addition & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
2168 | 2168 |
| |
2169 | 2169 |
| |
2170 | 2170 |
| |
| 2171 | + | |
2171 | 2172 |
| |
2172 | 2173 |
| |
2173 | 2174 |
| |
|
Lines changed: 1 addition & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
2455 | 2455 |
| |
2456 | 2456 |
| |
2457 | 2457 |
| |
| 2458 | + | |
2458 | 2459 |
| |
2459 | 2460 |
| |
2460 | 2461 |
| |
|
Lines changed: 1 addition & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
2403 | 2403 |
| |
2404 | 2404 |
| |
2405 | 2405 |
| |
| 2406 | + | |
2406 | 2407 |
| |
2407 | 2408 |
| |
2408 | 2409 |
| |
|
Lines changed: 1 addition & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
270 | 270 |
| |
271 | 271 |
| |
272 | 272 |
| |
| 273 | + | |
273 | 274 |
| |
274 | 275 |
| |
275 | 276 |
| |
|
Lines changed: 3 additions & 2 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
1786 | 1786 |
| |
1787 | 1787 |
| |
1788 | 1788 |
| |
1789 |
| - | |
1790 |
| - | |
| 1789 | + | |
| 1790 | + | |
1791 | 1791 |
| |
1792 | 1792 |
| |
1793 | 1793 |
| |
| |||
3026 | 3026 |
| |
3027 | 3027 |
| |
3028 | 3028 |
| |
| 3029 | + | |
3029 | 3030 |
| |
3030 | 3031 |
| |
3031 | 3032 |
| |
|
0 commit comments
Comments
(0)