From 0c22a5d429f1974ade279c65468f768d1b6a57fb Mon Sep 17 00:00:00 2001 From: Stefan Ritt Date: Thu, 5 Jun 2003 07:16:36 +0000 Subject: [PATCH] Creat boundary randomly SVN revision: 555 --- src/elog.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/elog.c b/src/elog.c index 1f1b24bc..0484e430 100755 --- a/src/elog.c +++ b/src/elog.c @@ -6,6 +6,9 @@ Contents: Electronic logbook utility $Log$ + Revision 1.5 2003/06/05 07:16:36 midas + Creat boundary randomly + Revision 1.4 2003/06/04 14:26:59 midas elog utility can read text from stdin @@ -51,6 +54,7 @@ #include #include #include +#include #ifdef _MSC_VER #include @@ -248,7 +252,8 @@ char host_name[256], boundary[80], str[80], *p; } /* compose content */ - strcpy(boundary, "---------------------------7d0bf1a60904bc"); + srand((unsigned)time(NULL)); + sprintf(boundary, "---------------------------%04X%04X%04X", rand(), rand(), rand()); strcpy(content, boundary); strcat(content, "\r\nContent-Disposition: form-data; name=\"cmd\"\r\n\r\nSubmit\r\n");