The DynDN.eS Blog

About DynDN.eS, eQmail, Gentoo & some other network stuff

User Tools

Site Tools


Dokuwiki: plugin isauth

This plugin allows to hide some content. It is a fork of the initial ifauth plugin, which seems to be unmaintained and its webpage at dokuwiki is confusing. Additional there is a rewrite at GitHub1). All the many inconsistencies forced me to fork.

Author Kai Peter
Type syntax
Version 2023-07-20
Works with: 2023-04-04 “Jack Jackrum”
  Download  plugin-isauth-latest.zip
Checksum: sha256sum

Syntax

Just wrap the text, where the access authorization shall be checked with Markup Language Style Tags:

[isauth account,@group]Text displayed if authorized[/isauth]
  • account: the user listed is allowed to see the text
  • @group: members of the group listed are allowed to see the text
  • !account: everyone except the user listed prefixed with ! is allowed to see the text (This is not the same as saying the user listed is NOT allowed to see the text. This condition does not restrict visibility to users authorized by previous rules. Every additional rule widens the number of users who can see the text.)
  • Any number of rules can be added to the list; the rules are OR'ed, so each additional rule expands the set of authorized viewers.

There MUST be no white space after a comma!

For backwards compatibility the syntax with  <  and  >  tags is still supported but deprecated.

More Examples

The “me” below stands for an existing user account (login name).

condition text is visible …
[isauth @admin,!me]**OK**[/isauth] if me is in group @admin, to everybody; otherwise to everyone in group @admin if me is not in it
[isauth !me,@admin]**OK**[/isauth] same as above
[isauth me]**OK**[/isauth] only to user me
[isauth !@admin]**OK**[/isauth] everybody who is not in group @admin
[isauth !@admin,me]**OK**[/isauth] everybody who is not in group @admin, and also to user me (whether he is in @admin or not)
[isauth @admin,me]**OK**[/isauth] everybody who is in group @admin, and also to user me (whether he is in @admin or not)
[isauth @admin,@other,me]**OK**[/isauth] everybody who is in group @admin, and everybody who is in group @other, and to user me

Caveats

  • the hidden text is still at the page, so it is not secure to hide sensible information (visible via “view page source”)
  • some syntax inside the tags will be broken, e.g. header lines

The plugin is indented to provide the content a bit cleaner, e.g. to hide incomplete potions of text which are not finished yet. Any other interpretation is beyond the scope of it!

Installation

Install the plugin using the Extension Manager. Copy the download link above, go to the Extension Manager, select the Manual Install tab and put the link into the Install from URL: field. Press the button Install.

Refer to Plugin Installation Instructions on how to install plugins.

Bugs / Feature Requests

Please report bugs or feature requests at the Issue Tracker.

Further Resources

Latest Changes


1)
As I wrote this initially it was last updated 2010 (8 years ago)

Comments

Error: Class "XMLReader" not found

Error: Class "XMLReader" not found

An unforeseen error has occured. This is most likely a bug somewhere. It might be a problem in the captcha plugin.

More info has been written to the DokuWiki error log.