[pmg-devel] [PATCH http-server/api/gui/docs v2] add attachment quarantine

Dominik Csapak d.csapak at proxmox.com
Mon Sep 30 14:55:23 CEST 2019


this series adds a new type of quarantine: 'attachment'

on 'Remove' actions, an admin can now copy the mail into the
attachment quarantine, while the mail with the removed attachment
will be sent to the recipient. now the admin can retrieve
the removed attachments, send it verbatim, or remove it

pmg-api patches 2-5 are general refactors, and could be applied
independently (although the later patches depend on them)

pmg-api patch 6,7 are improvements/fixes and only
tangentially related (mostly touch the same files)

changes from v1:
* different send_file approach:
  - gives either a scalar (filename) or a hash
  - in case of hash, uses a filehandle instead of path
    (this way, the caller can unlink the file while still being open)
* better error wording
* better refactoring

pve-http-server:

Dominik Csapak (1):
  AnyEvent: extend send_file with content-type

 PVE/APIServer/AnyEvent.pm | 39 +++++++++++++++++++++++++--------------
 1 file changed, 25 insertions(+), 14 deletions(-)

pmg-api:

Dominik Csapak (10):
  HTTPServer: extend download functionality
  add PMG::MIMEUtils helper package
  use the refactored helpers from PMG::MIMEUtils
  MailQueue: prepare for attachment quarantine
  API2/Quarantine: refactor quarantine listing api
  fix result verification for invalid mails
  RuleDB/Remove: improve attachment detection for 'remove all'
  RuleDB/Remove: add attachment quarantine option
  API2/Quarantine: add attachment quarantine api paths
  DBTools: add new default rule/objects for attachment quarantine

 src/Makefile               |   1 +
 src/PMG/API2/Quarantine.pm | 371 ++++++++++++++++++++++++++++---------
 src/PMG/DBTools.pm         |  17 ++
 src/PMG/HTMLMail.pm        |  23 +--
 src/PMG/HTTPServer.pm      |  10 +-
 src/PMG/MIMEUtils.pm       |  76 ++++++++
 src/PMG/MailQueue.pm       | 111 +++++------
 src/PMG/RuleDB/Remove.pm   |  59 +++++-
 src/PMG/Unpack.pm          |  58 +++---
 src/PMG/Utils.pm           |  22 +--
 src/tests/testdb.txt       |  11 ++
 11 files changed, 547 insertions(+), 212 deletions(-)
 create mode 100644 src/PMG/MIMEUtils.pm

pmg-gui:

Dominik Csapak (3):
  Action remove: add quarantine checkbox
  add render_filetype
  add Attachment Quarantine

 js/AttachmentGrid.js       |  61 ++++++++++++
 js/AttachmentQuarantine.js | 185 +++++++++++++++++++++++++++++++++++++
 js/Makefile                |   2 +
 js/NavigationTree.js       |   6 ++
 js/Utils.js                |  38 ++++++++
 5 files changed, 292 insertions(+)
 create mode 100644 js/AttachmentGrid.js
 create mode 100644 js/AttachmentQuarantine.js

pmg-docs:

Dominik Csapak (1):
  add info about attachment quarantine

 pmg-administration.adoc | 7 +++++++
 pmg-mail-filter.adoc    | 4 ++++
 2 files changed, 11 insertions(+)

-- 
2.20.1




More information about the pmg-devel mailing list