Compare commits

..

10 Commits

Author SHA1 Message Date
openeuler-ci-bot
7e4a864697
!19 【轻量级 PR】:update changelog date
From: @zhangshaoning_uniontech 
Reviewed-by: @small_leek 
Signed-off-by: @small_leek
2022-09-21 03:57:26 +00:00
zhangshaoning
120094ae3b
update changelog date 2022-05-12 08:23:07 +00:00
openeuler-ci-bot
70f3a892b4
!15 Resolve compilation failure of afflib
Merge pull request !15 from houyingchao/openEuler-22.03-LTS-Next
2022-01-11 09:44:07 +00:00
houyingchao
118beaccb4 Resolve compilation failure of afflib 2022-01-11 16:32:07 +08:00
openeuler-ci-bot
33c960b9c8 !9 Modify license of package afflib
From: @wang--ge
Reviewed-by: @small_leek
Signed-off-by: @small_leek
2020-12-16 14:30:46 +08:00
wang--ge
59d2114c92 modify license 2020-12-03 19:56:31 +08:00
openeuler-ci-bot
2abbe95495 !8 disable python2
From: @jackie_wu123
Reviewed-by: @small_leek
Signed-off-by: @small_leek
2020-11-02 11:58:57 +08:00
jackie_wu
162f214d7e disable python2 2020-11-02 09:33:17 +08:00
openeuler-ci-bot
7a413625a5 !7 Upgrade package
Merge pull request !7 from wang_yue111/master
2020-06-04 09:20:17 +08:00
wang_yue111
c8af3ec59c Upgrade package 2020-06-03 17:18:19 +08:00
4 changed files with 60 additions and 69 deletions

View File

@ -1,33 +0,0 @@
From 435a2ca802358a3debb6d164d2c33049131df81c Mon Sep 17 00:00:00 2001
From: Phillip Hellewell <sshock@gmail.com>
Date: Sat, 10 Mar 2018 18:05:39 -0700
Subject: [PATCH 3/4] Sanity check size passed to malloc...
Add sanity check before calling malloc in af_get_page() function to
avoid undefined behavior (e.g., seg fault) when dealing with a corrupt
AFF image with an invalid pagesize.
Issue found by Luis Rocha (luiscrocha@gmail.com).
---
lib/afflib_pages.cpp | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/lib/afflib_pages.cpp b/lib/afflib_pages.cpp
index 2569c2a..f8cf775 100644
--- a/lib/afflib_pages.cpp
+++ b/lib/afflib_pages.cpp
@@ -219,6 +219,11 @@ int af_get_page(AFFILE *af,int64_t pagenum,unsigned char *data,size_t *bytes)
return -3; // read error
}
+ /* Sanity check to avoid undefined behaviour when calling malloc below with pagesize from a corrupt AFF image. */
+ if(af->image_pagesize <= 0 || af->image_pagesize > 16*1024*1024)
+ return -1;
+
+
/* Now uncompress directly into the buffer provided by the caller, unless the caller didn't
* provide a buffer. If that happens, allocate our own...
*/
--
2.13.6

Binary file not shown.

View File

@ -1,22 +1,24 @@
Name: afflib Name: afflib
Version: 3.7.16 Version: 3.7.18
Release: 9 Release: 6
Summary: Libraries supporting advanced forensic formats Summary: Library to support the Advanced Forensic Format
License: LGPL-2.0 and LGPL-2.1 and GPL-2.0+ and Public Domain
License: BSD with advertising
URL: https://github.com/sshock/AFFLIBv3 URL: https://github.com/sshock/AFFLIBv3
Source0: %{url}/archive/v%{version}.tar.gz#/%{name}-%{version}.tar.gz Source0: %{url}/archive/v%{version}.tar.gz
Patch0: Sanity-check-size-passed-to-malloc.patch BuildRequires: gcc-c++ libtool curl-devel expat-devel ncurses-devel
BuildRequires: libtermcap-devel openssl-devel zlib-devel
BuildRequires: gcc-c++ libtool curl-devel expat-devel lzma-devel zlib-devel BuildRequires: python3 python3-devel python3-setuptools python3-Cython
BuildRequires: ncurses-devel openssl-devel python2-devel Provides: bundled(lzma) = 443
Provides: afftools = %{version}-%{release}
Obsoletes: afftools < %{version}-%{release}
%description %description
AFF® is an open and extensible file format designed to store Afflib is a library for support of the Advanced Forensic Format.
disk images and associated metadata.
%package -n afftools
Summary: The Utility for %{name}
Requires: %{name} = %{version}-%{release}
%description -n afftools
The %{name}-utils package contains utilities to use %{name}.
%package devel %package devel
Summary: Development files for %{name} Summary: Development files for %{name}
@ -24,44 +26,54 @@ Requires: %{name} = %{version}-%{release}
Requires: openssl-devel pkgconfig Requires: openssl-devel pkgconfig
%description devel %description devel
The %{name}-devel package contains libraries for The %{name}-devel package contains libraries for developing
developing applications that use %{name}. applications that use %{name}.
%package help %package -n python3-pyaff
Summary: Help for %{name} Summary: The python3 binding for the AFFLIB
Provides: python-pyaff(aarch-64) = 3.7.18-3
Provides: python-pyaff = 3.7.18-3
Obsoletes: python-pyaff < 3.7.18-3
%description help %description -n python3-pyaff
The %{name}-help package contains help for %{name}. Python3 bindings currently support a read-only file-like interface to AFFLIB and
basic metadata accessor functions. These bindings are not currently complete.
%prep %prep
%autosetup -p1 -n AFFLIBv3-%{version} %autosetup -p1 -n AFFLIBv3-%{version}
find lzma443 -type f -exec chmod 0644 {} ';' find lzma443 -type f -exec chmod 0644 {} ';'
chmod 0644 lib/base64.{h,cpp} chmod 0644 lib/base64.{h,cpp}
./bootstrap.sh ./bootstrap.sh
%build %build
%configure --enable-shared --disable-static --enable-python=yes --enable-s3=yes %configure --enable-shared --disable-static --enable-python=no --enable-s3=yes
sed -i 's|^hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=""|g' libtool sed -i 's|^hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=""|g' libtool
sed -i 's|^runpath_var=LD_RUN_PATH|runpath_var=DIE_RPATH_DIE|g' libtool sed -i 's|^runpath_var=LD_RUN_PATH|runpath_var=DIE_RPATH_DIE|g' libtool
sed -i -e 's! -shared ! -Wl,--as-needed\0!g' libtool sed -i -e 's! -shared ! -Wl,--as-needed\0!g' libtool
%make_build %make_build
cd pyaff
%global py_setup_args build_ext --include-dirs %{_builddir}/AFFLIBv3-%{version}/include --library-dirs %{_builddir}/AFFLIBv3-%{version}/lib/.libs
%py3_build
%install %install
%make_install %make_install
%delete_la %delete_la
cd pyaff
%py3_install
%post -p /sbin/ldconfig %post
%postun -p /sbin/ldconfig /sbin/ldconfig
%postun
/sbin/ldconfig
%files %files
%license COPYING %doc AUTHORS BUGLIST.txt ChangeLog NEWS README COPYING
%doc doc/announce_2.2.txt
%{_libdir}/*.so.* %{_libdir}/*.so.*
%files -n afftools
%{_bindir}/aff* %{_bindir}/aff*
%{python2_sitearch}/* %{_mandir}/man1/aff*.1.*
%files devel %files devel
%doc doc/crypto_design.txt doc/crypto_doc.txt %doc doc/crypto_design.txt doc/crypto_doc.txt
@ -69,14 +81,26 @@ sed -i -e 's! -shared ! -Wl,--as-needed\0!g' libtool
%{_libdir}/*.so %{_libdir}/*.so
%{_libdir}/pkgconfig/afflib.pc %{_libdir}/pkgconfig/afflib.pc
%files help %files -n python3-pyaff
%doc AUTHORS BUGLIST.txt ChangeLog NEWS README %doc pyaff/README COPYING
%doc doc/announce_2.2.txt %{python3_sitearch}/PyAFF*
%{_mandir}/man1/aff*.1.* %{python3_sitearch}/pyaff*
%changelog %changelog
* Wed Mar 04 2019 yangjian<yangjian79@huawei.com> - 3.7.16-9 * Tue Jan 11 2022 houyingchao <houyingchao@huawei.com> - 3.7.18-6
- Resolve compilation failure of afflib
* Thu Dec 03 2020 Ge Wang <wangge20@huawei.com> - 3.7.18-5
- modify license
* Wed Oct 21 2020 wutao <wutao61@huawei.com> - 3.7.18-4
- delete python2 modules
* Mon Jun 1 2020 wangyue <wangyue92@huawei.com> - 3.7.18-3
- Upgrade package
* Mon Mar 04 2019 yangjian<yangjian79@huawei.com> - 3.7.16-9
- Change buildrequires - Change buildrequires
* Wed Feb 22 2019 yangjian<yangjian79@huawei.com> - 3.7.16-8 * Fri Feb 22 2019 yangjian<yangjian79@huawei.com> - 3.7.16-8
- Package init - Package init

BIN
v3.7.18.tar.gz Normal file

Binary file not shown.