Szerző: Chris Meadors Dátum: Címzett: exim-users Tárgy: Re: [exim] prvs Always Day 100?
On Fri, 2006-02-17 at 10:25 -0500, Chris Meadors wrote: > I've got my Exim only calling prvs on local_domains now. Thanks David!
>
> But I've run into a different problem. All signed addresses seem to be
> for day 100. The hash matches, but then I'm informed that the signature
> has expired.
Replying to myself here. I've been trying to rip out the prvs_daystamp
function to make it stand alone. Wow, Exim has a lot of
inter-dependencies. :)
I finally got it working with only having to use mytypes.h along with
the string_format function and the string_vformat function it calls. I
removed the "case 'D'" and the log_write line from sting_vformat to
avoid having to pull in more code.
I'm compiling Exim on an x86_64 machine. So that TIME_T_FMT is defined
as "%lld". Changing that definition to "%ld" in my test makes the
prvs_daystamp return 196 today when passed a day_offset of 0 today. As
the code shipped with the "%lld" definition it always returns 100.
I'm not sure if the bug is in string_vformat, or the math of the
prvs_daystamp, or how to fix it. But I am pretty sure this is a bug.