diff options
author | jedgar <jedgar@FreeBSD.org> | 2001-01-25 03:19:53 +0000 |
---|---|---|
committer | jedgar <jedgar@FreeBSD.org> | 2001-01-25 03:19:53 +0000 |
commit | 9e022f1b0a6d26b54e9f77c182446fd37bd3df4f (patch) | |
tree | 7985bce401329d4a79f51b6343f368a43fd3d3dd /net-im/micq/files | |
parent | 6e46f1c8ac23ea89091fc72a74a66054ea48e847 (diff) | |
download | FreeBSD-ports-9e022f1b0a6d26b54e9f77c182446fd37bd3df4f.zip FreeBSD-ports-9e022f1b0a6d26b54e9f77c182446fd37bd3df4f.tar.gz |
- Update port to 0.4.6p1 (fixes remote buffer overflow)
- Add some additional buffer checks
Diffstat (limited to 'net-im/micq/files')
-rw-r--r-- | net-im/micq/files/patch-aa | 21 | ||||
-rw-r--r-- | net-im/micq/files/patch-ab | 11 | ||||
-rw-r--r-- | net-im/micq/files/patch-ac | 11 | ||||
-rw-r--r-- | net-im/micq/files/patch-ad | 20 | ||||
-rw-r--r-- | net-im/micq/files/patch-ae | 24 |
5 files changed, 77 insertions, 10 deletions
diff --git a/net-im/micq/files/patch-aa b/net-im/micq/files/patch-aa index 777dc8b..296b895 100644 --- a/net-im/micq/files/patch-aa +++ b/net-im/micq/files/patch-aa @@ -1,12 +1,13 @@ ---- Makefile.orig Mon Jul 3 02:10:31 2000 -+++ Makefile Mon Jul 3 02:12:24 2000 -@@ -5,8 +5,7 @@ - # Most options that were here and soem that weren't have been moved to config.h - # edit that file to set up options. - # +--- Makefile.orig Tue Jan 23 11:49:05 2001 ++++ Makefile Wed Jan 24 20:28:41 2001 +@@ -2,8 +2,8 @@ + # originally by Matt D. Smith + # rewritten by Rico Gloeckner <mc@verdinet.de> + -CC = gcc -CFLAGS = -O4 -Wall -DUNIX -+CFLAGS += -Wall -DUNIX - CFLAGS += -DENGLISH_LANG - #CFLAGS += -DBULGARIAN_LANG - #CFLAGS += -DPOLISH_LANG ++CC?= gcc ++CFLAGS+= -Wall -DUNIX + + # uncomment the line below for debuging info + #CFLAGS += -g diff --git a/net-im/micq/files/patch-ab b/net-im/micq/files/patch-ab new file mode 100644 index 0000000..5a0048f --- /dev/null +++ b/net-im/micq/files/patch-ab @@ -0,0 +1,11 @@ +--- mreadline.c.orig Tue Jan 23 11:49:05 2001 ++++ mreadline.c Wed Jan 24 22:01:31 2001 +@@ -359,7 +359,7 @@ + break; + } + } +- sprintf (s, "%s %s/", message_cmd, ++ snprintf (s, sizeof(s), "%s %s/", message_cmd, + tab_array[tab_pointer]); + clen = cpos = strlen (s); + R_undraw(); diff --git a/net-im/micq/files/patch-ac b/net-im/micq/files/patch-ac new file mode 100644 index 0000000..b44d774 --- /dev/null +++ b/net-im/micq/files/patch-ac @@ -0,0 +1,11 @@ +--- sendmsg.c.orig Tue Jan 23 11:49:05 2001 ++++ sendmsg.c Wed Jan 24 22:02:47 2001 +@@ -977,7 +977,7 @@ + { + char buf[450]; + +- sprintf( buf, "%s\xFE%s", url, description ); ++ snprintf( buf, sizeof(buf), "%s\xFE%s", url, description ); + icq_sendmsg( sok, uin, buf, URL_MESS ); + } + diff --git a/net-im/micq/files/patch-ad b/net-im/micq/files/patch-ad new file mode 100644 index 0000000..f4e5d68 --- /dev/null +++ b/net-im/micq/files/patch-ad @@ -0,0 +1,20 @@ +--- util_ui.c.orig Tue Jan 23 11:49:05 2001 ++++ util_ui.c Wed Jan 24 22:09:24 2001 +@@ -102,7 +102,7 @@ + assert( 2048 >= strlen( str ) ); + + va_start( args, str ); +- vsprintf( buf, str, args ); ++ vsnprintf( buf, sizeof(buf), str, args ); + k = write( fd, buf, strlen( buf ) ); + if ( k != strlen( buf ) ) + { +@@ -292,7 +292,7 @@ + + va_start( args, str ); + #ifndef CURSES_UI +- vsprintf( buf, str, args ); ++ vsnprintf( buf, sizeof(buf), str, args ); + str2 = buf; + while ( (void *) NULL != ( str1 = strchr( str2, '\x1b' ) ) ) + { diff --git a/net-im/micq/files/patch-ae b/net-im/micq/files/patch-ae new file mode 100644 index 0000000..9b877e4 --- /dev/null +++ b/net-im/micq/files/patch-ae @@ -0,0 +1,24 @@ +--- icq_response.c.orig Tue Jan 23 11:49:05 2001 ++++ icq_response.c Wed Jan 24 22:07:40 2001 +@@ -871,19 +871,12 @@ + } + *tmp = 0; + char_conv ("wc",data); +-// temporaryy fix to buffer overflow +-// should be solved better -mc +-// strcpy (url_desc,data); +- url_desc[0] = '\0'; +- strncat(url_desc,data,sizeof(url_data)-1); ++ strlcpy(url_desc,data,sizeof(url_data)); + + tmp++; + data = tmp; + char_conv ("wc",data); +-// same apllies here --mc +-// strcpy (url_data,data); +- url_data[0] = '\0'; +- strncat (url_data,data,sizeof(url_data)-1); ++ strlcpy(url_data,data,sizeof(url_data)); + + // and again + // sprintf (message,"Description: %s \n URL: %s",url_desc,url_data); |