[rt-users] Deleting one attachment
Matt Zagrabelny
mzagrabe at d.umn.edu
Wed Oct 19 12:39:04 EDT 2016
On Wed, Oct 19, 2016 at 11:28 AM, Ram <ram0502 at gmail.com> wrote:
> Hi all,
> A user at work added an attachment that violates corporate policy to a
> ticket; the ticket itself is valid and must be kept. I need to delete the
> attachment. A quick look at the rt-shredder tool does not make it apparent
> to me how to do this with rt-shredder. I can readily do it editing the db in
> mysql but I'd rather use rt-shredder if it will do the job.
> any help?
Running 4.2.12 here...
# /opt/rt4/sbin/rt-shredder --plugin list
Plugins list:
Objects
SQLDump
Summary
Tickets
Attachments
Users
So it looks like it can shred attachments.
/opt/rt4/sbin/rt-shredder --plugin help-Attachments
USAGE
masks
If any argument is marked with keyword `mask' then it means that this
argument support two special characters:
1) `*' matches any non empty sequence of the characters. For example
`*@example.com' will match any email address in `example.com' domain.
2) `?' matches exactly one character. For example `????' will match any
string four characters long.
NAME
RT::Shredder::Plugin::Attachments - search plugin for wiping
attachments.
ARGUMENTS
files_only - boolean value
Search only file attachments.
file - mask
Search files with specific file name only.
Example: '*.xl?' or '*.gif'
longer - attachment content size
Search attachments which content is longer than specified. You can use
trailing 'K' or 'M' character to specify size in kilobytes or megabytes.
Then perhaps something like:
/opt/rt4/sbin/rt-shredder --plugin
Attachments=files_only,1;file,some_secret_document.pdf
I didn't try the above and I would _for sure_ try it on a test system
first - at least a test ticket with a test attachment.
-m
More information about the rt-users
mailing list