I know that the node_access function in the node.module controls node view, update, delete and create permissions. What function controls node listing?

I recently updated my node_access function to restrict access to content, but those restrictions aren't showing up when I, for example, list recent posts are create a view of documents.

I read somewhere that node listing permissions where handled elsewhere. Can someone help me? Thanks.

Comments

hquadrat’s picture

I'm not sure of what you wanted to do. As I understand it, you want to manually restrict access to node-listing by changing your node.module?

I just know that restricting access to list certain nodes belonging to specific terms in taxonomy is possible through the taxonomy_access module: http://drupal.org/project/taxonomy_access. Maybe this helps you at least to find appropriate functions?

somebodysysop’s picture

I modified my node_access module to restrict access by taxnomy_access AND og. Details here: http://drupal.org/node/122173

That works fine. But, I understand that when it comes to node listings, it is db_rewrite_sql() that handles the permissions. So, right now, my users can list content they can't actually access.

My question is: What do I modify (db_rewrite_sql()?) in order to have node listings respect BOTH taxonomy_access AND og restrictions, and how?

Thanks!