Hi,
 I'm using reprepro in an automated import system, which parses the
output to figure out what happened when an import goes wrong and send
an email.
I'm using that line to understand if the .changes file is signed.
AFAICT, that was the only way to know that from reprepro. Is there
another way? As it is only printed if the verbose level is high, I
think it's useful to show some sort of info message.

Thanks,
Alberto Donato

On Fri, Jan 27, 2012 at 12:15 PM, Bernhard R. Link <[email protected]> wrote:
> package reprepro
> tags 657589 - patch
> thanks
>
> * Alberto Donato <[email protected]> [120127 10:48]:
>> When running the 'processincoming' command to import a non-signed
>> .changes file, the message
>>
>>  Data seems not to be signed trying to use directly...
>>
>> was included in the command ouput in version in reprepro 4.5.x.
>> Since 4.6.x it is not displayed anymore. This seems to be a
>> regression, the attached patch fixes it.
>
> The warning is now only printed if it looks strange (so there is a
> danger a signature is there but misinterpreted). If it looks like
> a regular unsigned file no warning is printed.
>
> The ChangeLog message is:
> | 2010-04-17
> |        * avoid 'Data seems not to be signed trying to use directly'
> |          message if data start like unsigned file should start.
>
>
>> Index: reprepro-4.8.2/signature.c
>> ===================================================================
>> --- reprepro-4.8.2.orig/signature.c   2011-12-09 10:44:44.032200314 +0100
>> +++ reprepro-4.8.2/signature.c        2011-12-09 10:45:04.900200290 +0100
>> @@ -742,8 +742,8 @@
>>
>>       /* fast-track unsigned chunks: */
>>       if (startofchanges[0] != '-' && *afterchanges == '\0') {
>> -             if (verbose > 5 && strncmp(startofchanges, "Format:", 7) != 0
>> -                             && strncmp(startofchanges, "Source:", 7) != 0)
>> +             if (verbose > 5 && (strncmp(startofchanges, "Format:", 7) != 0
>> +                             || strncmp(startofchanges, "Source:", 7) != 0))
>
> If the old behaviour is reverted, then this would not be the proper way:
> (strncmp(startofchanges, "Format:", 7) != 0 || strncmp(startofchanges, 
> "Source:", 7) != 0)
> would only be false if the files start both with "Format" and with
> "Source" at the same time. So if it was reverted, one should just remove
> the condition.
>
> Is there a reason you want this warning back in this case? I thought it
> was only seen as annoyance.
>
>
>        Bernhard R. Link



--
To UNSUBSCRIBE, email to [email protected]
with a subject of "unsubscribe". Trouble? Contact [email protected]

Reply via email to