I went back to see if I could find the discussion about this in the past. It was less than I thought. Most it was me posting with some feedback from Rod Taylor. The thread started with the subject "What user to defaults execute as?" on general, but I mutated the subject to "setuid for defaults, constraints and triggers (Was: What user to [sic] defaults execute as?)".
The summary is that I was suggesting that default expressions, triggers and constraints should all run as the table owner instead of the invoker as there was little use for them to need the access of the invoker, while there was benefit in having them run as the owner. In addition there is a mild security issue in that default expressions and constraints could be used as trojans so that inserting data into a table could allow that table owner the ability to do things they shouldn't be doing to the invoker's table. Though in practice anyone granted to the ability to create functions (which you need to exploit this) is already very highly trusted. ---------------------------(end of broadcast)--------------------------- TIP 3: Have you checked our extensive FAQ? http://www.postgresql.org/docs/faq