Restrict content based on a blacklist of words

I have a requirement to block / redact or at the very minimum provide the ability to report and alert administrators when certain terms are published within confluence pages. I appreciate that in general this such an approach is not best practice in terms of Wiki openness etc but I need a solution to support corporate governance policies.

4 answers

1 accepted

1 vote
David Simpson Community Champion Aug 08, 2011
Sounds like you need WTFilter: http://codegeist.atlassian.com/entry/167988
2 votes
Nicholas Muldoon Community Champion Oct 02, 2015

G'day @Jean-Paul,

Redaction for Confluence provides a more granular level of content visibility, enabling you to hide words or paragraphs within a page. Redacted content is not included in page exports or search results, ensuring that sensitive information stays private.

redaction-for-confluence 1120x548px Marketplace.png

May be useful for your scenario.

If you want more details on the add-on contact me via nick@arijea.com or +1 415 568 7064.

Regards,
Nicholas Muldoon
Arijea

Using the reporting plug-in, you could create a table of violators:

------------------------

Code:

-----------------------

{report-table}

{content-reporter:space=@self}

{or-filter}

{text-filter:content:body|include=dog,cat}

{text-filter:content:title|include=dog,cat}

{or-filter}

{content-reporter}

{report-column:title=Title}{report-info:page:title|link=true}{report-column}

{report-table}

------------------------
------------------------
This only searches a single space (whichever space contains the page with this content. It can search all spaces by changed "@self" to "@all". It may be slow in refreshing, depending upon your volume. It may make more sense to do a database query.
This example searches for the strings: "cat" and "dog". Replace that with your blacklist.
I do not know if you can subscribe to the page and it will run automatically. It may be a manual page visit, 1/day or whatever you need.

If you are able to hit the database with an sql query, or schedule a report, you could use a variant of this query. Pros: no plugin; cons: sql.

-- Query to locate current pages containing a specified string
-- Jim Birch 2011.01.28
select  -- top 100
 s.spacekey, c.TITLE, c.CREATOR, c.LASTMODIFIER, c.LASTMODDATE --, bc.body 
from
  dbo.CONTENT c
join
  dbo.BODYCONTENT bc
on
 c.CONTENTID = bc.CONTENTID
-- note: spaceid is null on old page versions so join on
-- space id selects only current pages.  Nice.
join
 dbo.SPACES s
on
 s.SPACEID = c.SPACEID
where
 bc.BODY like '%sometext%' 
order by
 s.spacekey, c.title

Suggest an answer

Log in or Sign up to answer
How to earn badges on the Atlassian Community

How to earn badges on the Atlassian Community

Badges are a great way to show off community activity, whether you’re a newbie or a Champion.

Learn more
Community showcase
Posted Jul 10, 2018 in Confluence

We want to see the templates you've created in Confluence!

Hi Community, Jessica here from the Confluence Product Marketing team!  July’s community challenge is all about sharing pictures  — and as an extension of our first post on what ...

910 views 23 12
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you