Compare commits

..

10 Commits

Author SHA1 Message Date
openeuler-ci-bot
79ce3d005b
!27 [sync] PR-24: Remove rpath
From: @openeuler-sync-bot 
Reviewed-by: @wang--ge 
Signed-off-by: @wang--ge
2024-08-19 01:11:45 +00:00
wk333
bc6089a38b Remove rpath
(cherry picked from commit 771e4c0b9fd173082298f63c390a95b8d6d27af6)
2024-08-16 16:05:00 +08:00
openeuler-ci-bot
c606416fa6
!23 Update to 0.12
From: @wk333 
Reviewed-by: @wang--ge 
Signed-off-by: @wang--ge
2023-10-19 01:10:53 +00:00
wk333
0f2aadcc29 Update to 0.12 2023-10-18 16:15:18 +08:00
openeuler-ci-bot
0ea9117ee1
!17 Fix CVE-2022-47021
From: @starlet-dx 
Reviewed-by: @gitee-cmd 
Signed-off-by: @gitee-cmd
2023-01-29 09:24:40 +00:00
starlet-dx
848080c5c0 Fix CVE-2022-47021 2023-01-29 15:32:05 +08:00
openeuler-ci-bot
ecfdc7b0ec !8 添加gcc依赖, 解决gcc command not found.
From: @shine_
Reviewed-by: @small_leek
Signed-off-by: @small_leek
2021-06-07 20:28:18 +08:00
shine_
f9b86dfc1a fix failed: gcc command not found. 2021-06-04 16:39:55 +08:00
openeuler-ci-bot
56a01647d9 !3 fix MemorySanitizer warning and yaml separator field
From: @maminjie
Reviewed-by: @zhanghua1831,@small_leek
Signed-off-by: @small_leek
2020-12-03 14:50:51 +08:00
maminjie
049299e074 fix MemorySanitizer warning and yaml separator field 2020-12-03 10:21:08 +08:00
6 changed files with 85 additions and 3 deletions

View File

@ -0,0 +1,24 @@
From 73915cab4bb5af47c07c9aa5b1436c8f339b6af3 Mon Sep 17 00:00:00 2001
From: maminjie <maminjie1@huawei.com>
Date: Thu, 3 Dec 2020 01:30:52 +0000
Subject: [PATCH] fix MemorySanitizer: use-of-uninitialized-value
---
src/opusfile.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/src/opusfile.c b/src/opusfile.c
index 8b000a2..889cb31 100644
--- a/src/opusfile.c
+++ b/src/opusfile.c
@@ -479,6 +479,7 @@ static int op_fetch_headers_impl(OggOpusFile *_of,OpusHead *_head,
int *_cserialnos,ogg_page *_og){
ogg_packet op;
int ret;
+ memset(&op,0,sizeof(ogg_packet));
if(_serialnos!=NULL)*_nserialnos=0;
/*Extract the serialnos of all BOS pages plus the first set of Opus headers
we see in the link.*/
--
2.23.0

40
CVE-2022-47021.patch Normal file
View File

@ -0,0 +1,40 @@
From 0a4cd796df5b030cb866f3f4a5e41a4b92caddf5 Mon Sep 17 00:00:00 2001
From: Ralph Giles <giles@thaumas.net>
Date: Tue, 6 Sep 2022 19:04:31 -0700
Subject: [PATCH] Propagate allocation failure from ogg_sync_buffer.
Instead of segfault, report OP_EFAULT if ogg_sync_buffer returns
a null pointer. This allows more graceful recovery by the caller
in the unlikely event of a fallible ogg_malloc call.
We do check the return value elsewhere in the code, so the new
checks make the code more consistent.
Thanks to https://github.com/xiph/opusfile/issues/36 for reporting.
Signed-off-by: Timothy B. Terriberry <tterribe@xiph.org>
Signed-off-by: Mark Harris <mark.hsj@gmail.com>
---
src/opusfile.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/src/opusfile.c b/src/opusfile.c
index ca219b2..3c3c81e 100644
--- a/src/opusfile.c
+++ b/src/opusfile.c
@@ -148,6 +148,7 @@ static int op_get_data(OggOpusFile *_of,int _nbytes){
int nbytes;
OP_ASSERT(_nbytes>0);
buffer=(unsigned char *)ogg_sync_buffer(&_of->oy,_nbytes);
+ if(OP_UNLIKELY(buffer==NULL))return OP_EFAULT;
nbytes=(int)(*_of->callbacks.read)(_of->stream,buffer,_nbytes);
OP_ASSERT(nbytes<=_nbytes);
if(OP_LIKELY(nbytes>0))ogg_sync_wrote(&_of->oy,nbytes);
@@ -1527,6 +1528,7 @@ static int op_open1(OggOpusFile *_of,
if(_initial_bytes>0){
char *buffer;
buffer=ogg_sync_buffer(&_of->oy,(long)_initial_bytes);
+ if(OP_UNLIKELY(buffer==NULL))return OP_EFAULT;
memcpy(buffer,_initial_data,_initial_bytes*sizeof(*buffer));
ogg_sync_wrote(&_of->oy,(long)_initial_bytes);
}

Binary file not shown.

BIN
opusfile-0.12.tar.gz Normal file

Binary file not shown.

View File

@ -1,12 +1,14 @@
Name: opusfile Name: opusfile
Version: 0.11 Version: 0.12
Release: 2 Release: 2
Summary: A high-level API provides seeking, decode, and playback of Opus streams Summary: A high-level API provides seeking, decode, and playback of Opus streams
License: BSD License: BSD
URL: http://www.opus-codec.org/ URL: http://www.opus-codec.org/
Source0: http://downloads.xiph.org/releases/opus/%{name}-%{version}.tar.gz Source0: http://downloads.xiph.org/releases/opus/%{name}-%{version}.tar.gz
Patch0000: 0001-fix-MemorySanitizer-use-of-uninitialized-value.patch
Patch0001: CVE-2022-47021.patch
BuildRequires: libogg-devel openssl-devel opus-devel BuildRequires: gcc libogg-devel openssl-devel opus-devel chrpath
%description %description
The opusfile library provides seeking, decode, and playback of Opus streams in the Ogg The opusfile library provides seeking, decode, and playback of Opus streams in the Ogg
@ -31,6 +33,7 @@ Development package for opusfile package.
%install %install
%make_install %make_install
%delete_la %delete_la
chrpath -d %{buildroot}/%{_libdir}/libopus*
%post %post
/sbin/ldconfig /sbin/ldconfig
@ -49,6 +52,21 @@ Development package for opusfile package.
%{_libdir}/{libopusfile.so,libopusurl.so} %{_libdir}/{libopusfile.so,libopusurl.so}
%changelog %changelog
* Fri Aug 16 2024 wangkai <13474090681@163.com> - 0.12-2
- Remove rpath
* Wed Oct 18 2023 wangkai <13474090681@163.com> - 0.12-1
- Update to 0.12
* Sun Jan 29 2023 yaoxin <yaoxin30@h-partners.com> - 0.11-5
- Fix CVE-2022-47021
* Wed Jun 02 2021 zhaoyao<zhaoyao32@huawei.com> - 0.11-4
- fixs faileds: /bin/sh: gcc: command not found.
* Thu Dec 03 2020 maminjie <maminjie1@huawei.com> - 0.11-3
- fix MemorySanitizer: use-of-uninitialized-value
* Sat Nov 30 2019 daiqianwen <daiqianwen@huawei.com> - 0.11-2 * Sat Nov 30 2019 daiqianwen <daiqianwen@huawei.com> - 0.11-2
- Package init - Package init

View File

@ -1,4 +1,4 @@
version_control: github version_control: github
src_repo: xiph/opusfile src_repo: xiph/opusfile
tag_prefix: ^v tag_prefix: ^v
seperator: . separator: .