diff --git a/www/tor-browser/Makefile b/www/tor-browser/Makefile index 99b94fd43973..485505ef1771 100644 --- a/www/tor-browser/Makefile +++ b/www/tor-browser/Makefile @@ -1,169 +1,169 @@ PORTNAME= tor-browser -DISTVERSION= 14.0.3 +DISTVERSION= 14.0.4 CATEGORIES= www net security wayland MASTER_SITES= TOR \ https://build-sources.tbb.torproject.org/:source1 \ LOCAL/jsm:source2 \ https://secure.informaction.com/%SUBDIR%/:source3 MASTER_SITE_SUBDIR= torbrowser/${DISTVERSION}/:DEFAULT \ download/releases/:source3 -DISTNAME= src-firefox-tor-browser-128.5.0esr-14.0-1-build2 -NOSCRIPT= noscript-11.5.2.xpi +DISTNAME= src-firefox-tor-browser-128.6.0esr-14.0-1-build1 +NOSCRIPT= noscript-12.1.1.xpi DISTFILES= ${DISTNAME}.tar.xz \ manual_215922.zip:source1 \ fonts-3--4348e1.tar.zst:source2 \ ${NOSCRIPT}:source3 MAINTAINER= freebsd@sysctl.cz COMMENT= Tor Browser for FreeBSD WWW= https://www.torproject.org/ LICENSE= MPL20 LICENSE_FILE= ${WRKSRC}/LICENSE BUILD_DEPENDS= nspr>=4.32:devel/nspr \ - nss>=3.94:security/nss \ + nss>=3.101:security/nss \ icu>=73.1:devel/icu \ libevent>=2.1.8:devel/libevent \ - harfbuzz>=8.2.2:print/harfbuzz \ + harfbuzz>=8.5.0:print/harfbuzz \ graphite2>=1.3.14:graphics/graphite2 \ - png>=1.6.39:graphics/png \ + png>=1.6.43:graphics/png \ dav1d>=1.0.0:multimedia/dav1d \ - libvpx>=1.13.1:multimedia/libvpx \ + libvpx>=1.14:multimedia/libvpx \ ${PYTHON_PKGNAMEPREFIX}sqlite3>0:databases/py-sqlite3@${PY_FLAVOR} \ v4l_compat>0:multimedia/v4l_compat \ autoconf2.13:devel/autoconf2.13 \ nasm:devel/nasm \ yasm:devel/yasm RUN_DEPENDS= tor:security/tor \ obfs4proxy:security/obfs4proxy-tor \ snowflake-client:security/snowflake-tor USES= compiler:c++11-lib libtool localbase:ldflags perl5 pkgconfig \ python:3.8+ shebangfix tar:xz USE_GECKO= gecko USE_GITHUB= nodefault TAG_L10N= f75c1e6a305e68161037337767ece88e9de940b9 GH_TUPLE= mozilla-l10n:firefox-l10n:${TAG_L10N}:ffl10n USE_GITLAB= nodefault GL_SITE= https://gitlab.torproject.org/ GL_ACCOUNT= tpo GL_PROJECT= translation:basebrowser translation:torbrowser TAG_BASE= caa431bbea1a76d7ad61eeda94086a1513762605 TAG_TOR= 4314d0a7ce780ffdf82b84e324bfbc437198f993 GL_TAGNAME= ${TAG_BASE}:basebrowser ${TAG_TOR}:torbrowser USE_MOZILLA= -sqlite LOCALES= ar ca cs da de el es-ES fa fi fr ga-IE he hu id is it ja ka ko \ lt mk ms my nb-NO nl pl pt-BR ro ru sq sv-SE th tr uk vi zh-CN \ zh-TW CONFIGURE_ENV+= BINDGEN_CFLAGS="-I${LOCALBASE}/include" \ MOZ_CHROME_MULTILOCALE="${LOCALES}" MAKE_ENV+= LOCALES="${LOCALES}" CFLAGS_powerpc64le= -DSQLITE_BYTEORDER=1234 SSP_UNSAFE= yes BUNDLE_LIBS= yes SUB_FILES= fonts.conf tor-browser.desktop torrc-defaults WRKSRC= ${WRKDIR}/${DISTNAME:S/src-//} MOZ_EXPORT+= MOZ_TELEMETRY_REPORTING="" \ MOZILLA_OFFICIAL="1" \ MOZ_OFFICIAL_BRANDING="1" \ MOZ_APP_DISPLAYNAME="Tor Browser" \ MOZ_APP_NAME="tor-browser" \ MOZ_CHROME_MULTILOCALE="${LOCALES}" MOZ_OPTIONS= --with-base-browser-version=${DISTVERSION} \ --enable-official-branding \ --enable-optimize \ --enable-bundled-fonts \ --disable-tests \ --disable-debug \ --disable-crashreporter \ --disable-webrtc \ --disable-parental-controls \ --enable-proxy-bypass-protection \ --disable-system-policies \ --disable-backgroundtasks \ --with-distribution-id=org.torproject \ --with-branding=browser/branding/tb-release .include "${.CURDIR}/../../www/firefox/Makefile.options" .include .if ${ARCH} == amd64 MOZ_OPTIONS+= --enable-rust-simd .endif .if ${ARCH} == powerpc64 MOZ_OPTIONS+= --without-wasm-sandboxed-libraries .else BUILD_DEPENDS+= ${LOCALBASE}/share/wasi-sysroot/lib/wasm32-wasi/libc++abi.a:devel/wasi-libcxx${LLVM_VERSION} \ ${LOCALBASE}/share/wasi-sysroot/lib/wasm32-wasi/libc.a:devel/wasi-libc@${LLVM_VERSION} \ wasi-compiler-rt${LLVM_VERSION}>0:devel/wasi-compiler-rt${LLVM_VERSION} MOZILLA_PLIST_DIRS= bin lib share/applications share/pixmaps \ share/tor-browser MOZ_OPTIONS+= --with-wasi-sysroot=${LOCALBASE}/share/wasi-sysroot .endif post-patch: @${REINPLACE_CMD} 's|LOCALBASE|${LOCALBASE}|g' \ "${WRKSRC}/browser/app/profile/000-tor-browser.js" @${REINPLACE_CMD} 's|%%LOCALBASE%%|${LOCALBASE}|g' \ ${WRKSRC}/browser/app/nsBrowserApp.cpp ${MKDIR} ${WRKSRC}/tmp-manual ${UNZIP_NATIVE_CMD} -d ${WRKSRC}/tmp-manual ${DISTDIR}/manual_215922.zip pre-configure: @${REINPLACE_CMD} 's|export MOZ_GOOGLE_.*||g' ${WRKSRC}/.mozconfig ${PYTHON_CMD} ${FILESDIR}/packagemanual.py ${WRKSRC}/tmp-manual/public \ ${WRKSRC}/browser/base/content/manual post-configure: ${MKDIR} ${WRKDIR}/.mozbuild/l10n-central ${CP} -r ${WRKDIR}/firefox-l10n-${TAG_L10N}/* \ ${WRKDIR}/.mozbuild/l10n-central .for i in ${LOCALES} ${CP} ${WRKDIR}/translation-${TAG_BASE}/${i}/base-browser.ftl \ ${WRKDIR}/.mozbuild/l10n-central/${i}/toolkit/toolkit/global/ ${CP} ${WRKDIR}/translation-${TAG_BASE}/${i}/newIdentity.properties \ ${WRKDIR}/.mozbuild/l10n-central/${i}/browser/chrome/browser/ ${CP} ${WRKDIR}/translation-${TAG_BASE}/${i}/securityLevel.properties \ ${WRKDIR}/.mozbuild/l10n-central/${i}/browser/chrome/browser/ ${CP} ${WRKDIR}/translation-${TAG_TOR}/${i}/tor-browser.ftl \ ${WRKDIR}/.mozbuild/l10n-central/${i}/toolkit/toolkit/global/ ${MKDIR} ${WRKSRC}/toolkit/torbutton/chrome/locale/${i}/ .for j in aboutTBUpdate.dtd brand.dtd brand.properties onionLocation.properties \ settings.properties torConnect.properties torbutton.dtd \ torbutton.properties torlauncher.properties ${CP} ${WRKDIR}/translation-${TAG_TOR}/${i}/${j} \ ${WRKSRC}/toolkit/torbutton/chrome/locale/${i}/ .endfor ${CP} -r ${WRKDIR}/translation-${TAG_TOR}/${i}/branding \ ${WRKSRC}/toolkit/torbutton/chrome/locale/${i} .endfor post-build: MOZBUILD_STATE_PATH=${WRKDIR}/.mozbuild AB_CD="multi" MOZ_AUTOMATION="1" \ PATH="`find ${WRKRDIR}/.mozbuild/srcdirs -name build -type d -print`/bin:${PATH}" \ ${WRKSRC}/mach package-multi-locale --locales ${LOCALES} post-install: @${MKDIR} ${STAGEDIR}${DATADIR} ${INSTALL_DATA} ${WRKDIR}/torrc-defaults \ ${STAGEDIR}${DATADIR}/torrc-defaults ${INSTALL_DATA} ${WRKDIR}/tor-browser.desktop \ ${STAGEDIR}${PREFIX}/share/applications/tor-browser.desktop ${MKDIR} ${STAGEDIR}${PREFIX}/lib/tor-browser/fontconfig ${MKDIR} ${STAGEDIR}${PREFIX}/lib/tor-browser/fonts ${INSTALL_DATA} ${WRKDIR}/fonts.conf \ ${STAGEDIR}${PREFIX}/lib/tor-browser/fontconfig/fonts.conf (cd ${WRKDIR}/fonts && \ ${COPYTREE_SHARE} "*.otf *.ttf" ${STAGEDIR}${PREFIX}/lib/tor-browser/fonts) ${MKDIR} ${STAGEDIR}${PREFIX}/lib/tor-browser/distribution/extensions ${INSTALL_DATA} ${DISTDIR}/${NOSCRIPT} \ "${STAGEDIR}${PREFIX}/lib/tor-browser/distribution/extensions/{73a6fe31-595d-460b-a920-fcc0f8843232}.xpi" .include diff --git a/www/tor-browser/distinfo b/www/tor-browser/distinfo index dfee4191ccfc..f0491ded0230 100644 --- a/www/tor-browser/distinfo +++ b/www/tor-browser/distinfo @@ -1,15 +1,15 @@ -TIMESTAMP = 1733043195 -SHA256 (src-firefox-tor-browser-128.5.0esr-14.0-1-build2.tar.xz) = e2b0c7f43d1159064d9b1875d5dc378f1176048dea4900e331d776b4cdafdada -SIZE (src-firefox-tor-browser-128.5.0esr-14.0-1-build2.tar.xz) = 610942584 +TIMESTAMP = 1736350323 +SHA256 (src-firefox-tor-browser-128.6.0esr-14.0-1-build1.tar.xz) = e3f9bc9102131754cfb819640d355375a2f25a66252afd57e051f1d6568ffe9b +SIZE (src-firefox-tor-browser-128.6.0esr-14.0-1-build1.tar.xz) = 610905384 SHA256 (manual_215922.zip) = b5ed703f54d52e9f197320f3698e936d585a3fed23cc4f9fbf59edce2869f885 SIZE (manual_215922.zip) = 28305786 SHA256 (fonts-3--4348e1.tar.zst) = 7fbbecece6de777f196982f6eb567970a6d8e7ac2bf5b1ad6b90e1ea36374032 SIZE (fonts-3--4348e1.tar.zst) = 27441580 -SHA256 (noscript-11.5.2.xpi) = 460aaa6484bf8422415dfe08260e8536866e3731ed5b8b7913cf4b7b1333493a -SIZE (noscript-11.5.2.xpi) = 959788 +SHA256 (noscript-12.1.1.xpi) = f9639e63ffcfc352036de00e4ff6694bb0ca65a0bb8fbd103bd08f32dc1ff31a +SIZE (noscript-12.1.1.xpi) = 980626 SHA256 (mozilla-l10n-firefox-l10n-f75c1e6a305e68161037337767ece88e9de940b9_GH0.tar.gz) = 16760cc32c79ed1a52e3a7c19050004a4eee871cfe236f1f96418899a42dbc2b SIZE (mozilla-l10n-firefox-l10n-f75c1e6a305e68161037337767ece88e9de940b9_GH0.tar.gz) = 66268851 SHA256 (tpo-translation-caa431bbea1a76d7ad61eeda94086a1513762605_GL0.tar.gz) = f9ceb52d163979cd07fb66012a2c5d58a25218f5d3b5a2ffa4e42099739e7147 SIZE (tpo-translation-caa431bbea1a76d7ad61eeda94086a1513762605_GL0.tar.gz) = 769386 SHA256 (tpo-translation-4314d0a7ce780ffdf82b84e324bfbc437198f993_GL0.tar.gz) = 3908c78b89449026943bc024bb995d78146504b834d9156bb0f5f97944888a5d SIZE (tpo-translation-4314d0a7ce780ffdf82b84e324bfbc437198f993_GL0.tar.gz) = 2593543 diff --git a/www/tor-browser/files/patch-bug1626236 b/www/tor-browser/files/patch-bug1626236 index ccb417b61f15..ae3b522f6b90 100644 --- a/www/tor-browser/files/patch-bug1626236 +++ b/www/tor-browser/files/patch-bug1626236 @@ -1,88 +1,92 @@ https://bugzilla.mozilla.org/show_bug.cgi?id=1626236 https://bug1626236.bmoattachments.org/attachment.cgi?id=9137096 # HG changeset patch # User msirringhaus@suse.de # Date 1582805876 -3600 # Thu Feb 27 13:17:56 2020 +0100 # Node ID cc3d09abea31068e57f1ab918782f9f86fc6a158 # Parent 9cd90914846f667f18babc491a74c164ae5d6e9f imported patch decoder_workaround.patch -diff -r 9cd90914846f image/decoders/nsGIFDecoder2.cpp ---- image/decoders/nsGIFDecoder2.cpp Thu Feb 27 12:57:14 2020 +0100 -+++ image/decoders/nsGIFDecoder2.cpp Fri Mar 27 13:06:18 2020 +0100 -@@ -422,6 +422,9 @@ +diff --git image/decoders/nsGIFDecoder2.cpp image/decoders/nsGIFDecoder2.cpp +index ebb0b7d..d52ef47 100644 +--- image/decoders/nsGIFDecoder2.cpp ++++ image/decoders/nsGIFDecoder2.cpp +@@ -422,6 +422,9 @@ void nsGIFDecoder2::ConvertColormap(uint32_t* aColormap, uint32_t aColors) { MOZ_ASSERT(mSwizzleFn); uint8_t* data = reinterpret_cast(aColormap); mSwizzleFn(data, data, aColors); +#if MOZ_BIG_ENDIAN() + SwizzleRow(SurfaceFormat::A8R8G8B8, SurfaceFormat::B8G8R8A8)(data, data, aColors); +#endif } LexerResult nsGIFDecoder2::DoDecode(SourceBufferIterator& aIterator, -diff -r 9cd90914846f image/decoders/nsJPEGDecoder.cpp ---- image/decoders/nsJPEGDecoder.cpp Thu Feb 27 12:57:14 2020 +0100 -+++ image/decoders/nsJPEGDecoder.cpp Fri Mar 27 13:06:18 2020 +0100 -@@ -263,6 +263,9 @@ +diff --git image/decoders/nsJPEGDecoder.cpp image/decoders/nsJPEGDecoder.cpp +index 9ea4403..d82772c 100644 +--- image/decoders/nsJPEGDecoder.cpp ++++ image/decoders/nsJPEGDecoder.cpp +@@ -257,6 +257,9 @@ LexerTransition nsJPEGDecoder::ReadJPEGData( case JCS_YCbCr: // By default, we will output directly to BGRA. If we need to apply // special color transforms, this may change. +#if MOZ_BIG_ENDIAN() + mInfo.out_color_space = MOZ_JCS_EXT_NATIVE_ENDIAN_XRGB; +#else switch (SurfaceFormat::OS_RGBX) { case SurfaceFormat::B8G8R8X8: mInfo.out_color_space = JCS_EXT_BGRX; -@@ -277,6 +280,7 @@ +@@ -271,6 +274,7 @@ LexerTransition nsJPEGDecoder::ReadJPEGData( mState = JPEG_ERROR; return Transition::TerminateFailure(); } +#endif break; case JCS_CMYK: case JCS_YCCK: -diff -r 9cd90914846f image/decoders/nsPNGDecoder.cpp ---- image/decoders/nsPNGDecoder.cpp Thu Feb 27 12:57:14 2020 +0100 -+++ image/decoders/nsPNGDecoder.cpp Fri Mar 27 13:06:18 2020 +0100 -@@ -361,7 +361,7 @@ +diff --git image/decoders/nsPNGDecoder.cpp image/decoders/nsPNGDecoder.cpp +index e3e4ef4..3cc7315 100644 +--- image/decoders/nsPNGDecoder.cpp ++++ image/decoders/nsPNGDecoder.cpp +@@ -356,7 +356,7 @@ LexerResult nsPNGDecoder::DoDecode(SourceBufferIterator& aIterator, IResumable* aOnResume) { MOZ_ASSERT(!HasError(), "Shouldn't call DoDecode after error!"); - return mLexer.Lex(aIterator, aOnResume, + LexerResult res = mLexer.Lex(aIterator, aOnResume, [=](State aState, const char* aData, size_t aLength) { switch (aState) { case State::PNG_DATA: -@@ -371,6 +371,14 @@ +@@ -366,6 +366,14 @@ LexerResult nsPNGDecoder::DoDecode(SourceBufferIterator& aIterator, } MOZ_CRASH("Unknown State"); }); + +#if MOZ_BIG_ENDIAN() + if(res.is() && res.as() == TerminalState::SUCCESS) { + NativeEndian::swapToLittleEndianInPlace((uint32_t*)(mImageData), mImageDataLength / 4); + } +#endif + + return res; } LexerTransition nsPNGDecoder::ReadPNGData( -diff -r 9cd90914846f image/decoders/nsWebPDecoder.cpp ---- image/decoders/nsWebPDecoder.cpp Thu Feb 27 12:57:14 2020 +0100 -+++ image/decoders/nsWebPDecoder.cpp Fri Mar 27 13:06:18 2020 +0100 -@@ -237,7 +237,12 @@ +diff --git image/decoders/nsWebPDecoder.cpp image/decoders/nsWebPDecoder.cpp +index e58ca92..2056ebb 100644 +--- image/decoders/nsWebPDecoder.cpp ++++ image/decoders/nsWebPDecoder.cpp +@@ -247,7 +247,12 @@ nsresult nsWebPDecoder::CreateFrame(const OrientedIntRect& aFrameRect) { // WebP doesn't guarantee that the alpha generated matches the hint in the // header, so we always need to claim the input is BGRA. If the output is // BGRX, swizzling will mask off the alpha channel. +#if MOZ_BIG_ENDIAN() + mBuffer.colorspace = MODE_ARGB; + SurfaceFormat inFormat = mFormat; +#else SurfaceFormat inFormat = SurfaceFormat::OS_RGBA; +#endif SurfacePipeFlags pipeFlags = SurfacePipeFlags(); if (mFormat == SurfaceFormat::OS_RGBA && diff --git a/www/tor-browser/files/patch-bug1876366 b/www/tor-browser/files/patch-bug1876366 new file mode 100644 index 000000000000..78483c3fbab7 --- /dev/null +++ b/www/tor-browser/files/patch-bug1876366 @@ -0,0 +1,23 @@ +commit 46a89fb0319d673b3139a068e3d89aed9f44fc16 +Author: Christoph Moench-Tegeder + + use gdk legacy cursor interface by default + + Upstream https://bugzilla.mozilla.org/show_bug.cgi?id=1876366#c16 + hints that we could re-test this once we have GTK 3.24.42 (with the + now-current gtk3-3.24.41 the original problem is still reproducable, + but toggling this flag does fix it for me) + +diff --git modules/libpref/init/StaticPrefList.yaml modules/libpref/init/StaticPrefList.yaml +index 835450712a12..f2249006c36d 100644 +--- modules/libpref/init/StaticPrefList.yaml ++++ modules/libpref/init/StaticPrefList.yaml +@@ -16070,7 +16070,7 @@ + # Whether to use gtk legacy cursor API. + - name: widget.gtk.legacy-cursors.enabled + type: bool +- value: false ++ value: true + mirror: always + + # Whether to use gtk high contrast themes to disable content styling like on diff --git a/www/tor-browser/files/patch-dom_media_webrtc_third__party__build_webrtc.mozbuild b/www/tor-browser/files/patch-dom_media_webrtc_third__party__build_webrtc.mozbuild new file mode 100644 index 000000000000..3242763d64a6 --- /dev/null +++ b/www/tor-browser/files/patch-dom_media_webrtc_third__party__build_webrtc.mozbuild @@ -0,0 +1,27 @@ +commit 0a4dfe06e072222335bff7724b64a1f479e56569 +Author: Christoph Moench-Tegeder + + flag WEBRTC_USE_PIPEWIRE just as on Linux + +diff --git dom/media/webrtc/third_party_build/webrtc.mozbuild dom/media/webrtc/third_party_build/webrtc.mozbuild +index 940420e3f8c4..08e07f77056f 100644 +--- dom/media/webrtc/third_party_build/webrtc.mozbuild ++++ dom/media/webrtc/third_party_build/webrtc.mozbuild +@@ -40,6 +40,17 @@ if CONFIG["MOZ_WEBRTC"]: + DEFINES["HAVE_WINSOCK2_H"] = True + elif CONFIG["OS_TARGET"] in ("DragonFly", "FreeBSD", "NetBSD", "OpenBSD"): + DEFINES["WEBRTC_BSD"] = True ++ if ( ++ CONFIG["TARGET_CPU"] == "x86" ++ or CONFIG["TARGET_CPU"] == "x86_64" ++ or CONFIG["TARGET_CPU"] == "arm" ++ or CONFIG["TARGET_CPU"] == "aarch64" ++ or ( ++ CONFIG["TARGET_ENDIANNESS"] == "little" ++ and CONFIG["TARGET_CPU"].startswith("mips") ++ ) ++ ): ++ DEFINES["WEBRTC_USE_PIPEWIRE"] = True + elif CONFIG["OS_TARGET"] == "Android": + DEFINES["WEBRTC_LINUX"] = True + DEFINES["WEBRTC_ANDROID"] = True diff --git a/www/tor-browser/files/patch-tools_profiler_core_patform.cpp b/www/tor-browser/files/patch-tools_profiler_core_patform.cpp deleted file mode 100644 index 905e6d7bbe49..000000000000 --- a/www/tor-browser/files/patch-tools_profiler_core_patform.cpp +++ /dev/null @@ -1,51 +0,0 @@ -commit 45a7951cb6a9b1735b9b6cec89db69b5933715c7 -Author: Christoph Moench-Tegeder -Date: Mon Mar 28 21:54:35 2022 +0200 - - FreeBSD can use sched_getcpu() from 1400046/1300524 on - -diff --git tools/profiler/core/platform.cpp tools/profiler/core/platform.cpp -index 92bcc1100687..2f17a88942a8 100644 ---- tools/profiler/core/platform.cpp -+++ tools/profiler/core/platform.cpp -@@ -111,6 +111,20 @@ - # include - #endif - -+#if defined(GP_OS_freebsd) -+#include -+// "after making CPU_SET macros compatible with glibc" -+# if __FreeBSD_version > 1400045 || (__FreeBSD_version > 1300523 && __FreeBSD_version < 1400000) -+# include -+# else -+# if __x86_64__ || __i386__ -+// similar cpuid_count() trick as on Darwin, using LLVM -+// but not for all CPUs -+# include -+# endif -+# endif -+#endif -+ - #if defined(GP_OS_windows) - # include - -@@ -6368,6 +6382,19 @@ void profiler_mark_thread_awake() { - cpuId = ebx >> 24; - } - # endif -+#elif defined(GP_OS_freebsd) -+# if __FreeBSD_version > 1400045 || (__FreeBSD_version > 1300523 && __FreeBSD_version < 1400000) -+ cpuId = sched_getcpu(); -+# elif defined(__amd64__) -+ unsigned int eax, ebx, ecx, edx; -+ __cpuid_count(1, 0, eax, ebx, ecx, edx); -+ // Check if we have an APIC. -+ if ((edx & (1 << 9))) { -+ // APIC ID is bits 24-31 of EBX -+ cpuId = ebx >> 24; -+ } -+# endif -+// the fallthrough is cpuID = 0 - #else - cpuId = sched_getcpu(); - #endif