[pmwiki-users] (:pagelist:) broken when using UserAuth2 and beta45

Patrick R. Michaud pmichaud at pobox.com
Sat May 19 08:53:42 CDT 2007


On Sat, May 19, 2007 at 03:32:40PM +0200, ThomasP wrote:
> Hello,
> 
> as I discover, the pagelist markup is indeed broken when using UserAuth2.
> (It didn't do this with the old pmwiki.)
> 
> Patrick, do you have any idea why this could happen? All permission
> queries are passed, and I hope also I delivered the right return value
> back from the $AuthFunction. (see below)

PmWiki's built-in authorization function puts in a number of
"pseudo attributes" as part of the returned page.  They are:

    $page['=auth'][$level]     - true if the visitor is authorized at $level
    $page['=passwd'][$level]   - the value of any password field for $level
    $page['=pwsource'][$level] - where the password field is coming from
                                 (e.g., site, group, page)

The (:pagelist:) code uses $page['=auth']['read'] to decide
if the visitor has read permission to the page.  It uses
$page['=passwd']['read'] to determine if the page has any sort
of read restrictions on it.

I'm pretty sure these have been around since at least 2.0.0, although
the pagelist.php script didn't start using them until recently.

Pm



More information about the pmwiki-users mailing list