Thanks Thomas, that's a great solution.
Can I ask, if $this->{rcpt} is the recipient, what's the variable for the
envelope sender/s?
Is this something that might appear in future revisions of ASSP2?
Many thanks
Nick
On 24 Jun 2013, at 18:32, Thomas Eckardt <[email protected]> wrote:
>> Alternatively, is there a way to write the SMTP recipient
>> address to the headers before the file is written to the virusscan
>> directory, and then I can parse through the file and get it this way.
>
>
>> X-Assp-Intended-For: contains the envelope sender if
> AddIntendedForHeader is set.
>
> I don't think that our header is merged at file scan time in V1 nor V2 -
> so 'X-Assp-Intended-For' is not available.
>
> Only if V2 is using the ASSP_AFC Plugin - all merged X-ASSP- headers will
> be available - but the Plugin processes the mail MIME-part for MIME-part
> and there will be no MIME header available in the temp-scan-files.
>
>
> Nick,
>
> it would be easy to change the code to provide the information you
> requested. But the next user will possibly need some other or more
> information. I'll think about, how we can add an API or something similar.
>
> For now you can change the code:
>
> look in to the 'sub FileScanOK_Run {' and find the sequence
>
> $cmd = "$FileScanCMD 2>&1";
> $cmd =~ s/FILENAME/$runfile/igo;
> $cmd =~ s/NUMBER/$WorkerNumber/igo;
> $cmd =~ s/FILESCANDIR/$rundir/igo;
> d("filescan: running - $cmd");
>
> change this to :
>
> $cmd = "$FileScanCMD 2>&1";
> $cmd =~ s/FILENAME/$runfile/igo;
> $cmd =~ s/NUMBER/$WorkerNumber/igo;
> $cmd =~ s/FILESCANDIR/$rundir/igo;
> $cmd =~ s/RCPT/"'".$this->{rcpt}."'"/igoe;
> d("filescan: running - $cmd");
>
> the literal RCPT will then be replaced by the space separated list of all
> envelope recipients surrounded by single quotes - like:
>
> '[email protected] [email protected] [email protected]'
> or simply
> '[email protected]'
>
> Changing the code this way, will provide the requested information with
> and without using the ASSP_AFC Plugin.
>
> Thomas
>
>
>
>
>
>
> Von: "Fritz Borgstedt" <[email protected]>
> An: "For Users of ASSP" <[email protected]>,
> Datum: 24.06.2013 18:55
> Betreff: Re: [Assp-user] Get recipient email address from File Scan
> Command??
>
>
>
> For Users of ASSP <[email protected]> schreibt:
>> Alternatively, is there a way to write the SMTP recipient
>> address to the headers before the file is written to the virusscan
>> directory, and then I can parse through the file and get it this way.
>
>
>
> X-Assp-Intended-For: contains the envelope sender if
> AddIntendedForHeader is set.
>
>
> ------------------------------------------------------------------------------
> This SF.net email is sponsored by Windows:
>
> Build for Windows Store.
>
> http://p.sf.net/sfu/windows-dev2dev
> _______________________________________________
> Assp-user mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/assp-user
>
>
>
>
> DISCLAIMER:
> *******************************************************
> This email and any files transmitted with it may be confidential, legally
> privileged and protected in law and are intended solely for the use of the
>
> individual to whom it is addressed.
> This email was multiple times scanned for viruses. There should be no
> known virus in this email!
> *******************************************************
>
>
> ------------------------------------------------------------------------------
> This SF.net email is sponsored by Windows:
>
> Build for Windows Store.
>
> http://p.sf.net/sfu/windows-dev2dev
> _______________________________________________
> Assp-user mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/assp-user
______________________________________________
Giacom email security by www.messagestream.com
------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:
Build for Windows Store.
http://p.sf.net/sfu/windows-dev2dev
_______________________________________________
Assp-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/assp-user