Accepting request 33759 from Kernel:kdump
Copy from Kernel:kdump/makedumpfile based on submit request 33759 from user coolo OBS-URL: https://build.opensuse.org/request/show/33759 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/makedumpfile?expand=0&rev=32
This commit is contained in:
committed by
Git OBS Bridge
parent
1f221fe707
commit
3ef968901e
@@ -1,3 +0,0 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:b160859a8c3549771dc2a5dd605c4f8386ebb21acf35064b8ff8e2c08d413fc7
|
||||
size 54185
|
3
makedumpfile-1.3.5.tar.bz2
Normal file
3
makedumpfile-1.3.5.tar.bz2
Normal file
@@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:4ceff188bd7a0defe6159ac7ca7839584e84614c2e64b99b363b55b9667d4df6
|
||||
size 57397
|
@@ -4,8 +4,8 @@
|
||||
|
||||
--- a/Makefile
|
||||
+++ b/Makefile
|
||||
@@ -4,10 +4,10 @@ VERSION=1.3.3
|
||||
DATE=20 April 2009
|
||||
@@ -4,10 +4,10 @@ VERSION=1.3.5
|
||||
DATE=11 November 2009
|
||||
|
||||
CC = gcc
|
||||
-CFLAGS = -g -O2 -Wall -D_FILE_OFFSET_BITS=64 \
|
||||
@@ -23,6 +23,6 @@
|
||||
makedumpfile: $(SRC) $(OBJ_ARCH)
|
||||
- $(CC) $(CFLAGS) $(OBJ_ARCH) -o $@ $< -static -ldw -lelf -lz
|
||||
+ $(CC) $(CFLAGS) $(OBJ_ARCH) -o $@ $< -Wl,-Bstatic -ldw -lelf -Wl,-Bdynamic -lz
|
||||
gzip -c ./makedumpfile.8 > ./makedumpfile.8.gz
|
||||
|
||||
clean:
|
||||
echo .TH MAKEDUMPFILE 8 \"$(DATE)\" \"makedumpfile v$(VERSION)\" \"Linux System Administrator\'s Manual\" > temp.8
|
||||
grep -v "^.TH MAKEDUMPFILE 8" makedumpfile.8 >> temp.8
|
||||
mv temp.8 makedumpfile.8
|
||||
|
37
makedumpfile-fix-buffer-overflow.diff
Normal file
37
makedumpfile-fix-buffer-overflow.diff
Normal file
@@ -0,0 +1,37 @@
|
||||
From 7f02d0afa45d4c14f91cb4a0a0202dd80786e95a Mon Sep 17 00:00:00 2001
|
||||
From: Bernhard Walle <bernhard@bwalle.de>
|
||||
Date: Sun, 21 Feb 2010 10:26:16 +0100
|
||||
Subject: [PATCH] Fix buffer overflow when writing dh->signature
|
||||
|
||||
Fix following compile warning when building with gcc 4.5 and with the
|
||||
flags '-O2 -Wall -D_FORTIFY_SOURCE=2 -fstack-protector -funwind-tables
|
||||
-fasynchronous-unwind-tables -g -O2 -Wall'.
|
||||
|
||||
In function 'strcpy',
|
||||
inlined from 'write_kdump_header' at makedumpfile.c:5457:8: \
|
||||
/usr/include/bits/string3.h:107:3: warning: call to \
|
||||
__builtin___strcpy_chk will always overflow destination buffer
|
||||
|
||||
Solution: Don't copy the terminating zero byte.
|
||||
|
||||
Signed-off-by: Bernhard Walle <bernhard@bwalle.de>
|
||||
---
|
||||
makedumpfile.c | 2 +-
|
||||
1 files changed, 1 insertions(+), 1 deletions(-)
|
||||
|
||||
diff --git a/makedumpfile.c b/makedumpfile.c
|
||||
index 4fa6f50..855c718 100644
|
||||
--- a/makedumpfile.c
|
||||
+++ b/makedumpfile.c
|
||||
@@ -5454,7 +5454,7 @@ write_kdump_header(void)
|
||||
/*
|
||||
* Write common header
|
||||
*/
|
||||
- strcpy(dh->signature, KDUMP_SIGNATURE);
|
||||
+ strncpy(dh->signature, KDUMP_SIGNATURE, strlen(KDUMP_SIGNATURE));
|
||||
dh->header_version = 3;
|
||||
dh->block_size = info->page_size;
|
||||
dh->sub_hdr_size = sizeof(kh) + info->size_vmcoreinfo;
|
||||
--
|
||||
1.6.4.2
|
||||
|
@@ -1,3 +1,40 @@
|
||||
-------------------------------------------------------------------
|
||||
Sun Feb 28 11:02:33 UTC 2010 - jengelh@medozas.de
|
||||
|
||||
- SPARC porting: use ExclusiveArch instead of ExcludeArch
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Sun Feb 21 08:47:56 UTC 2010 - bernhard@bwalle.de
|
||||
|
||||
- Fix buffer overflow that prevents build in Factory.
|
||||
- Update to 1.3.5
|
||||
* Features
|
||||
o Store vmcoreinfo data into a dumpfile in the kdump-
|
||||
compressed format.
|
||||
o Read vmcoreinfo data from a kdump-compressed dumpfile.
|
||||
o Support kdump-compressed format for input file.
|
||||
o Add dump filtering on an x86_64 xen domain-0.
|
||||
o Save utsname data into disk_dump_header.
|
||||
o Add linux-2.6.30 - 2.6.31 support.
|
||||
* Bugfix
|
||||
o Fix some lacks of free(). (by Minoru Usui)
|
||||
* Code Cleanup
|
||||
o Set the calculated value to dh->sub_hdr_size.
|
||||
o Fix some indents in write_kdump_header().
|
||||
o Unify the name of kdump_sub_header.
|
||||
o Fix the typo of DISKDUMP_HEADER_BLOCKS.
|
||||
o Add the description about re-filtering into manpage.
|
||||
o Fix the description in manpage and README.
|
||||
o Add some comments to code for the readability.
|
||||
o Remove VERSION_LINUX_2_6_XX.
|
||||
o Add paddr_to_pfn() and pfn_to_paddr() macros.
|
||||
o Merge the version information of makedumpfile.
|
||||
o Merge the PT_NOTE methods of both elf64 and elf32.
|
||||
o Reduce some indents in exclude_unnecessary_pages().
|
||||
o Remove unnecessary spaces.
|
||||
o read_disk_dump_header() and read_kdump_sub_header().
|
||||
o Use DISKDUMP_HDADER_BLOCKS for the readability.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Mon Apr 27 15:10:26 CEST 2009 - ptesarik@suse.cz
|
||||
|
||||
|
@@ -1,7 +1,7 @@
|
||||
#
|
||||
# spec file for package makedumpfile (Version 1.3.3)
|
||||
# spec file for package makedumpfile (Version 1.3.5)
|
||||
#
|
||||
# Copyright (c) 2009 SUSE LINUX Products GmbH, Nuernberg, Germany.
|
||||
# Copyright (c) 2010 SUSE LINUX Products GmbH, Nuernberg, Germany.
|
||||
#
|
||||
# All modifications and additions to the file contributed by third parties
|
||||
# remain the property of their copyright owners, unless otherwise agreed
|
||||
@@ -25,16 +25,17 @@ BuildRequires: libdw-devel
|
||||
%else
|
||||
BuildRequires: libdw-devel libdw1 libelf-devel libelf0 libelf1
|
||||
%endif
|
||||
License: GPL v2 or later
|
||||
Version: 1.3.3
|
||||
License: GPLv2+
|
||||
Version: 1.3.5
|
||||
Release: 1
|
||||
Summary: Partial kernel dump
|
||||
Group: System/Kernel
|
||||
Url: https://sourceforge.net/projects/makedumpfile/
|
||||
Source: %{name}-%{version}.tar.bz2
|
||||
Patch0: %{name}-coptflags.diff
|
||||
Patch1: %{name}-fix-buffer-overflow.diff
|
||||
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
||||
ExcludeArch: s390 s390x ppc
|
||||
ExclusiveArch: %ix86 x86_64 ia64 ppc64
|
||||
|
||||
%description
|
||||
makedumpfile is a dump program to shorten the size of dump file. It
|
||||
@@ -51,6 +52,7 @@ Authors:
|
||||
%prep
|
||||
%setup -q
|
||||
%patch0 -p1
|
||||
%patch1 -p1
|
||||
|
||||
%build
|
||||
make COPTFLAGS="$RPM_OPT_FLAGS"
|
||||
|
Reference in New Issue
Block a user