Navigation

    Kopano
    • Register
    • Login
    • Search
    • Categories
    • Get Official Kopano Support
    • Recent
    Statement regarding the closure of the Kopano community forum and the end of the community edition

    removing old virus contaminated attachments in Kopano files outside db

    Kopano Groupware Core
    1
    1
    185
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • Michael Niehren
      Michael Niehren last edited by

      Hi,

      i’ve got the following problem. In the users mailbox there are old virus contaminated mail’s, which
      the virus-scanner not recognized at the time they arrived.
      I’ve found and installed successfully a script (kopano-scan-attachments.py) which goes throught
      the users mailbox and scan’s all mails again. If a virus was found, the attachment is exchanged
      with an text-attachment… In the script this is done with
      email.delete(attachment)
      message = ‘The attachment with the name %s has been removed because it was infected with %s’ % (
      attachment.name, virus)
      email.create_attachment(‘virus-removed.txt’, message)

      After that the user sees only this text-attachment instead of the virus attachement. Everything fine.

      But if i run the virus-scanner over the filesystem (the Attachment-Dir), it still find’s the virus in
      the old attachment-file, which also still has an entry in the singleinstances table.

      So my question is, how to remove thes old attachment-files without damaging the integrity, so that the
      filesystem is also virus-clean ?

      best regards
      Michael

      1 Reply Last reply Reply Quote 0
      • First post
        Last post