title: How do I manage authorization (not authentication) with node and a postgresql db?
body: <p>This question is regarding authorization, not authentication which i will be managing with passportjs. How do i restrict access for data that's bound to specific users without spreading <code>user_id</code>'s all over every table in the database? </p>
  
  <p>Should i create a new database user for each new user of my app and restrict access that way? Or is the "user id in every table" approach actually a good way to go?</p>
  
  <p>I'm working on a project right now where someone else wrote the authorization logic and it works using a kind of <code>authorization path</code> in the code so it can find which user a resource belongs to using some breadcrumb logic.</p>
  
  <p>But I'm really at a loss here and I'm having a hard time finding any information regarding this since almost all articles that I find are about authentication rather than authorization. And I do not mean access to a resource, but rather the filtration of data returned from a resource that the user has access to.</p>