Resolves: #1606506 - telnet: FTBFS in Fedora rawhide
Resolves: #1505954 - telnet failing to parse .telnetrc due to strncpy used on overlaping buffers
This commit is contained in:
parent
7c71d97df9
commit
a88283db8c
19
netkit-telnet-0.17-telnetrc.patch
Normal file
19
netkit-telnet-0.17-telnetrc.patch
Normal file
@ -0,0 +1,19 @@
|
|||||||
|
diff --git a/telnet/commands.c b/telnet/commands.c
|
||||||
|
index 636fb5c..c0cc9b9 100644
|
||||||
|
--- a/telnet/commands.c
|
||||||
|
+++ b/telnet/commands.c
|
||||||
|
@@ -2217,11 +2217,11 @@ cmdrc(char *m1, char *m2)
|
||||||
|
if (isspace(line[0]))
|
||||||
|
continue;
|
||||||
|
if (strncasecmp(line, m1, l1) == 0)
|
||||||
|
- strncpy(line, &line[l1], sizeof(line) - l1);
|
||||||
|
+ memmove(line, &line[l1], sizeof(line) - l1);
|
||||||
|
else if (strncasecmp(line, m2, l2) == 0)
|
||||||
|
- strncpy(line, &line[l2], sizeof(line) - l2);
|
||||||
|
+ memmove(line, &line[l2], sizeof(line) - l2);
|
||||||
|
else if (strncasecmp(line, "DEFAULT", 7) == 0)
|
||||||
|
- strncpy(line, &line[7], sizeof(line) - 7);
|
||||||
|
+ memmove(line, &line[7], sizeof(line) - 7);
|
||||||
|
else
|
||||||
|
continue;
|
||||||
|
if (line[0] != ' ' && line[0] != '\t' && line[0] != '\n')
|
10
telnet.spec
10
telnet.spec
@ -3,7 +3,7 @@
|
|||||||
Summary: The client program for the Telnet remote login protocol
|
Summary: The client program for the Telnet remote login protocol
|
||||||
Name: telnet
|
Name: telnet
|
||||||
Version: 0.17
|
Version: 0.17
|
||||||
Release: 73%{?dist}
|
Release: 74%{?dist}
|
||||||
Epoch: 1
|
Epoch: 1
|
||||||
License: BSD
|
License: BSD
|
||||||
Group: Applications/Internet
|
Group: Applications/Internet
|
||||||
@ -39,8 +39,9 @@ Patch27: telnet-0.17-force-ipv6-ipv4.patch
|
|||||||
Patch28: netkit-telnet-0.17-core-dump.patch
|
Patch28: netkit-telnet-0.17-core-dump.patch
|
||||||
Patch29: netkit-telnet-0.17-gcc7.patch
|
Patch29: netkit-telnet-0.17-gcc7.patch
|
||||||
Patch30: netkit-telnet-0.17-manpage.patch
|
Patch30: netkit-telnet-0.17-manpage.patch
|
||||||
|
Patch31: netkit-telnet-0.17-telnetrc.patch
|
||||||
|
|
||||||
BuildRequires: ncurses-devel systemd
|
BuildRequires: ncurses-devel systemd gcc gcc-c++
|
||||||
BuildRequires: perl-interpreter
|
BuildRequires: perl-interpreter
|
||||||
|
|
||||||
%description
|
%description
|
||||||
@ -93,6 +94,7 @@ mv telnet telnet-NETKIT
|
|||||||
%patch28 -p1 -b .core-dump
|
%patch28 -p1 -b .core-dump
|
||||||
%patch29 -p1 -b .gcc7
|
%patch29 -p1 -b .gcc7
|
||||||
%patch30 -p1 -b .manpage
|
%patch30 -p1 -b .manpage
|
||||||
|
%patch31 -p1 -b .telnetrc
|
||||||
|
|
||||||
%build
|
%build
|
||||||
%ifarch s390 s390x
|
%ifarch s390 s390x
|
||||||
@ -157,6 +159,10 @@ install -p -m644 %SOURCE6 ${RPM_BUILD_ROOT}%{_unitdir}/telnet.socket
|
|||||||
%{_mandir}/man8/telnetd.8*
|
%{_mandir}/man8/telnetd.8*
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Mon Jul 23 2018 Michal Ruprich <mruprich@redhat.com> - 1:0.17-74
|
||||||
|
- Resolves: #1606506 - telnet: FTBFS in Fedora rawhide
|
||||||
|
- Resolves: #1505954 - telnet failing to parse .telnetrc due to strncpy used on overlaping buffers
|
||||||
|
|
||||||
* Sat Jul 14 2018 Fedora Release Engineering <releng@fedoraproject.org> - 1:0.17-73
|
* Sat Jul 14 2018 Fedora Release Engineering <releng@fedoraproject.org> - 1:0.17-73
|
||||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user