Modify

Opened 5 years ago

Closed 20 months ago

#5492 closed defect (worksforme)

Text visible in editing

Reported by: anonymous Owned by: turkanis
Priority: normal Component: AccessMacro
Severity: normal Keywords:
Cc: g1itch Trac Release: 0.12

Description

In your example..

{{{
#!access
#allow(TICKET_ADMIN)

some text for ticket admins
}}}

user, having WIKI_EDIT cat press "Edit this page" for reading and modifying protected text, so this construction make sence only if #allow(WIKI_EDIT) specified.

Attachments (0)

Change History (7)

comment:1 Changed 5 years ago by turkanis

  • Status changed from new to assigned

You're right that it doesn't make much sense to try to hide parts of a wiki page from people who have permission to edit the page, so this macro will be useful when there are users without WIKI_EDIT permissions.

I don't understand your comment about the example you quoted. It seems to make sense for there to be parts of wiki pages only ticket admins can see.

comment:2 Changed 5 years ago by rjollos

Just starting to test this out, and so made a note about what you mention here on the wiki page.

comment:3 follow-up: Changed 5 years ago by tekknokrat

It would be great if only the part that is shown to the user is editable. When comparing to mediawiki there it is possible to edit explicit chapters of the page. With introducing such a feature to your plugin you would therefore kill two birds with a stone. Perhaps you can also combine access logic with headings syntax e.g. something like:

{{{
#!access
#allow(TICKET_ADMIN)
=== heading3 ===
}}}

comment:4 follow-up: Changed 4 years ago by g1itch

  • Cc g1itch added; anonymous removed

I found a worst case recently :(

In my wiki anonymous users have no WIKI_EDIT. But there is a link "Download in other formats: Plain Text", which makes content visible for everyone.

I'm searching for plugin, which makes a sort of "public pages", accessible by WIKI_VIEW and rest - by some special permission, with ability to select public pages on Administration page and without extra mainnav locations.

comment:5 Changed 4 years ago by anonymous

Yeah, that looks like a problem. I haven't had time to figure out if it's possible to fix the other reported bug (relating to history) without a patch.

Thanks for the info.

comment:6 in reply to: ↑ 3 Changed 20 months ago by rjollos

Replying to tekknokrat:

It would be great if only the part that is shown to the user is editable. When comparing to mediawiki there it is possible to edit explicit chapters of the page. With introducing such a feature to your plugin you would therefore kill two birds with a stone.

SectionEditPlugin implements that feature, but in a very messy way. Section editing really needs to be implemented in the Trac core. There is a proposal (t:TracDev/Proposals/AdvancedWikiOperations) and ticket (t:#1024) for this feature.

comment:7 in reply to: ↑ 4 Changed 20 months ago by rjollos

  • Resolution set to worksforme
  • Status changed from assigned to closed

Replying to g1itch:

I found a worst case recently :(

In my wiki anonymous users have no WIKI_EDIT. But there is a link "Download in other formats: Plain Text", which makes content visible for everyone.

This is also described in #5554, therefore I'm going to close this ticket. The limitations of the plugin have been captured on the project wiki page.

I'm searching for plugin, which makes a sort of "public pages", accessible by WIKI_VIEW and rest - by some special permission, with ability to select public pages on Administration page and without extra mainnav locations.

If you want to restrict access to certain pages, you can use t:TracFineGrainedPermissions. For an editor, you can use the FineGrainedPageAuthzEditorPlugin, which will be integrated into the AccountManagerPlugin eventually.

Add Comment

Modify Ticket

Action
as closed The owner will remain turkanis.
The resolution will be deleted. Next status will be 'reopened'.
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.