diff options
author | lawrance <lawrance@FreeBSD.org> | 2005-05-04 21:35:55 +0800 |
---|---|---|
committer | lawrance <lawrance@FreeBSD.org> | 2005-05-04 21:35:55 +0800 |
commit | 2a6e8f42b59ed095036af160a41ca12c676bbe10 (patch) | |
tree | 0e6f679fe0100c1b41f8252dca1fe19ce5fbce80 /security | |
parent | 671b8de138eaee0d068c91e0f75d0ac1d7ba3ae4 (diff) | |
download | freebsd-ports-gnome-2a6e8f42b59ed095036af160a41ca12c676bbe10.tar.gz freebsd-ports-gnome-2a6e8f42b59ed095036af160a41ca12c676bbe10.tar.zst freebsd-ports-gnome-2a6e8f42b59ed095036af160a41ca12c676bbe10.zip |
Fix condition where strlen() is called on non null-terminated string.
PR: ports/72654
Submitted by: David Gilbert <dgilbert@daveg.ca>
Approved by: pat (maintainer, timeout)
Approved by: clement (mentor)
Diffstat (limited to 'security')
-rw-r--r-- | security/rain/files/patch-source__rain_icmp.c | 11 | ||||
-rw-r--r-- | security/rain/files/patch-source__rain_igmp.c | 11 | ||||
-rw-r--r-- | security/rain/files/patch-source__rain_tcp.c | 11 | ||||
-rw-r--r-- | security/rain/files/patch-source__rain_udp.c | 11 |
4 files changed, 44 insertions, 0 deletions
diff --git a/security/rain/files/patch-source__rain_icmp.c b/security/rain/files/patch-source__rain_icmp.c new file mode 100644 index 000000000000..1288fb93d156 --- /dev/null +++ b/security/rain/files/patch-source__rain_icmp.c @@ -0,0 +1,11 @@ +--- source/rain_icmp.c.orig Fri Aug 17 07:36:45 2001 ++++ source/rain_icmp.c Wed Apr 20 01:18:32 2005 +@@ -256,7 +256,7 @@ + } + + +- pkt->tot_len = (sizeof(struct icmp) + strlen(buffer)); ++ pkt->tot_len = (sizeof(struct icmp) + sizeof(char)*packetsize); + + + /* diff --git a/security/rain/files/patch-source__rain_igmp.c b/security/rain/files/patch-source__rain_igmp.c new file mode 100644 index 000000000000..0849e01100c1 --- /dev/null +++ b/security/rain/files/patch-source__rain_igmp.c @@ -0,0 +1,11 @@ +--- source/rain_igmp.c.orig Fri Aug 17 07:37:15 2001 ++++ source/rain_igmp.c Wed Apr 20 01:18:45 2005 +@@ -114,7 +114,7 @@ + } + + +- pkt->tot_len = (sizeof(struct igmp) + strlen(buffer)); ++ pkt->tot_len = (sizeof(struct igmp) + sizeof(char)*packetsize); + + + /* diff --git a/security/rain/files/patch-source__rain_tcp.c b/security/rain/files/patch-source__rain_tcp.c new file mode 100644 index 000000000000..cc2b8d7970db --- /dev/null +++ b/security/rain/files/patch-source__rain_tcp.c @@ -0,0 +1,11 @@ +--- source/rain_tcp.c.orig Fri Aug 17 07:36:07 2001 ++++ source/rain_tcp.c Wed Apr 20 01:19:04 2005 +@@ -244,7 +244,7 @@ + } + + +- pkt->tot_len = (sizeof(struct tcphdr) + strlen(buffer)); ++ pkt->tot_len = (sizeof(struct tcphdr) + sizeof(char)*packetsize); + + + /* diff --git a/security/rain/files/patch-source__rain_udp.c b/security/rain/files/patch-source__rain_udp.c new file mode 100644 index 000000000000..b16319b01e6e --- /dev/null +++ b/security/rain/files/patch-source__rain_udp.c @@ -0,0 +1,11 @@ +--- source/rain_udp.c.orig Fri Aug 17 07:36:26 2001 ++++ source/rain_udp.c Wed Apr 20 01:19:27 2005 +@@ -105,7 +105,7 @@ + buffer[(sizeof(struct ip) + sizeof(struct udphdr)) + i] = pkt->payload[i]; + } + +- pkt->tot_len = (sizeof(struct udphdr) + strlen(buffer)); ++ pkt->tot_len = (sizeof(struct udphdr) + sizeof(char)*packetsize); + + + /* |