diff options
author | trevor <trevor@FreeBSD.org> | 2001-03-25 09:59:39 +0800 |
---|---|---|
committer | trevor <trevor@FreeBSD.org> | 2001-03-25 09:59:39 +0800 |
commit | 79aeb81d882eab5be9064384a644b11c6517158f (patch) | |
tree | 18713ff700e73361205365398c4a74899dbe829b /mail | |
parent | 8bdf4598bc261b231f381f06e4e9888cc3b13557 (diff) | |
download | freebsd-ports-gnome-79aeb81d882eab5be9064384a644b11c6517158f.tar.gz freebsd-ports-gnome-79aeb81d882eab5be9064384a644b11c6517158f.tar.zst freebsd-ports-gnome-79aeb81d882eab5be9064384a644b11c6517158f.zip |
Add a patch to take out of the Message-ID header the information
about the operating system, the version of Pine, and the word
"PINE". As described in http://www.crimelabs.net/docs/passive.html
this information could be of use to someone with malicious
intentions.
PR: 26051 (duplicated as 26052)
Approved by: maintainer
Diffstat (limited to 'mail')
-rw-r--r-- | mail/pine4/files/patch-reply.c | 37 |
1 files changed, 37 insertions, 0 deletions
diff --git a/mail/pine4/files/patch-reply.c b/mail/pine4/files/patch-reply.c new file mode 100644 index 000000000000..50b4a4a354b5 --- /dev/null +++ b/mail/pine4/files/patch-reply.c @@ -0,0 +1,37 @@ +--- pine/reply.c.orig Wed Jan 24 18:35:05 2001 ++++ pine/reply.c Sun Feb 11 12:15:03 2001 +@@ -4967,23 +4967,24 @@ + char * + generate_message_id() + { +- static short osec = 0, cnt = 0; ++ struct timeval tp; ++ struct timezone tzp; ++ static short osec = 0; ++ static char cnt; + char *id; + time_t now; + struct tm *now_x; + + now = time((time_t *)0); + now_x = localtime(&now); +- id = (char *)fs_get(128 * sizeof(char)); ++ id = (char *)fs_get(384 * sizeof(char)); + +- if(now_x->tm_sec == osec){ +- cnt++; +- }else{ +- cnt = 0; +- osec = now_x->tm_sec; +- } +- sprintf(id,"<Pine.%.4s.%.20s.%02d%02d%02d%02d%02d%02d%X.%d@%.50s>", +- SYSTYPE, pine_version, (now_x->tm_year) % 100, now_x->tm_mon + 1, ++ cnt = 'A'; ++ if(gettimeofday(&tp, &tzp) == 0) ++ cnt += (time_t)tp.tv_usec % ('Z' - 'A'); ++ ++ sprintf(id,"<%d%02d%02d%02d%02d%02d.%c%d@%s>", ++ (now_x->tm_year) + 1900, now_x->tm_mon + 1, + now_x->tm_mday, now_x->tm_hour, now_x->tm_min, now_x->tm_sec, + cnt, getpid(), ps_global->hostname); + |