diff options
author | Isaac Yu <isaacyu1@isaacyu1.com> | 2023-02-03 17:54:24 -0800 |
---|---|---|
committer | Willy Sudiarto Raharjo <willysr@slackbuilds.org> | 2023-02-04 22:17:57 +0700 |
commit | 125d967321568c5e89dbe34fdc0e2b3ce43ef18d (patch) | |
tree | 448ffbdd2fca93534dd606cdf2f55a0522e0b13d /python | |
parent | e728a511efea45098278018c15685eff69024651 (diff) |
python/pywayland: Removed (replaced by python3-pywayland)
Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
Diffstat (limited to 'python')
-rw-r--r-- | python/pywayland/CVE_2007_4559.patch | 38 | ||||
-rw-r--r-- | python/pywayland/README | 6 | ||||
-rw-r--r-- | python/pywayland/pywayland.SlackBuild | 99 | ||||
-rw-r--r-- | python/pywayland/pywayland.info | 10 | ||||
-rw-r--r-- | python/pywayland/slack-desc | 19 |
5 files changed, 0 insertions, 172 deletions
diff --git a/python/pywayland/CVE_2007_4559.patch b/python/pywayland/CVE_2007_4559.patch deleted file mode 100644 index 437747cecbcba..0000000000000 --- a/python/pywayland/CVE_2007_4559.patch +++ /dev/null @@ -1,38 +0,0 @@ -This patch was taken from upstream pywayland 0.4.15: -https://github.com/flacjacket/pywayland/pull/42 ---- a/doc/protocol_build.py 2022-07-24 11:03:10.000000000 -0700 -+++ b/doc/protocol_build.py 2022-12-20 20:00:48.659884422 -0800 -@@ -14,6 +14,24 @@ - ) - ) - -+def _is_within_directory(directory, target): -+ """Helper to check for CVE-2007-4559""" -+ abs_directory = os.path.abspath(directory) -+ abs_target = os.path.abspath(target) -+ -+ prefix = os.path.commonprefix([abs_directory, abs_target]) -+ -+ return prefix == abs_directory -+ -+ -+def _safe_extractall(tar, path=".", members=None, *, numeric_owner=False): -+ """Helper to check for CVE-2007-4559""" -+ for member in tar.getmembers(): -+ member_path = os.path.join(path, member.name) -+ if not is_within_directory(path, member_path): -+ raise Exception("Attempted Path Traversal in Tar File") -+ -+ tar.extractall(path, members, numeric_owner=numeric_owner) - - def protocols_build(output_dir): - from pywayland.scanner import Protocol -@@ -26,7 +44,7 @@ - protocol_dest = "wayland-protocols-{}".format(protocols_version) - urllib.request.urlretrieve(protocols_source, protocol_dest + ".tar.xz") - with tarfile.open(protocol_dest + ".tar.xz") as f: -- f.extractall() -+ _safe_extractall(f) - - # walk the directory and generate all the protocols - protocol_files = [wayland_file] + sorted( diff --git a/python/pywayland/README b/python/pywayland/README deleted file mode 100644 index 6695b8b85bf83..0000000000000 --- a/python/pywayland/README +++ /dev/null @@ -1,6 +0,0 @@ -PyWayland provides a wrapper to the libwayland library using the CFFI -library to provide access to the Wayland library calls and written in -pure Python. - -pywayland 0.4.14 is the last possible version for Slackware 15.0. -Newer versions of pywayland require a newer python-setuptools. diff --git a/python/pywayland/pywayland.SlackBuild b/python/pywayland/pywayland.SlackBuild deleted file mode 100644 index 85ee42c6619ef..0000000000000 --- a/python/pywayland/pywayland.SlackBuild +++ /dev/null @@ -1,99 +0,0 @@ -#!/bin/bash - -# Slackware build script for pywayland - -# Copyright 2022 Isaac Yu <isaacyu1@isaacyu1.com> -# All rights reserved. -# -# Redistribution and use of this script, with or without modification, is -# permitted provided that the following conditions are met: -# -# 1. Redistributions of this script must retain the above copyright -# notice, this list of conditions and the following disclaimer. -# -# THIS SOFTWARE IS PROVIDED BY THE AUTHOR "AS IS" AND ANY EXPRESS OR IMPLIED -# WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -# MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO -# EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, -# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; -# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, -# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR -# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - -cd $(dirname $0) ; CWD=$(pwd) - -PRGNAM=pywayland -VERSION=${VERSION:-0.4.14} -BUILD=${BUILD:-2} -TAG=${TAG:-_SBo} -PKGTYPE=${PKGTYPE:-tgz} - -if [ -z "$ARCH" ]; then - case "$( uname -m )" in - i?86) ARCH=i586 ;; - arm*) ARCH=arm ;; - *) ARCH=$( uname -m ) ;; - esac -fi - -# If the variable PRINT_PACKAGE_NAME is set, then this script will report what -# the name of the created package would be, and then exit. This information -# could be useful to other scripts. -if [ ! -z "${PRINT_PACKAGE_NAME}" ]; then - echo "$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE" - exit 0 -fi - -TMP=${TMP:-/tmp/SBo} -PKG=$TMP/package-$PRGNAM -OUTPUT=${OUTPUT:-/tmp} - -if [ "$ARCH" = "i586" ]; then - SLKCFLAGS="-O2 -march=i586 -mtune=i686" - LIBDIRSUFFIX="" -elif [ "$ARCH" = "i686" ]; then - SLKCFLAGS="-O2 -march=i686 -mtune=i686" - LIBDIRSUFFIX="" -elif [ "$ARCH" = "x86_64" ]; then - SLKCFLAGS="-O2 -fPIC" - LIBDIRSUFFIX="64" -else - SLKCFLAGS="-O2" - LIBDIRSUFFIX="" -fi - -set -e - -rm -rf $PKG -mkdir -p $TMP $PKG $OUTPUT -cd $TMP -rm -rf $PRGNAM-$VERSION -tar xvf $CWD/$PRGNAM-$VERSION.tar.gz -cd $PRGNAM-$VERSION -chown -R root:root . -find -L . \ - \( -perm 777 -o -perm 775 -o -perm 750 -o -perm 711 -o -perm 555 \ - -o -perm 511 \) -exec chmod 755 {} \; -o \ - \( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \ - -o -perm 440 -o -perm 400 \) -exec chmod 644 {} \; - -# Backport patch from pywayland 0.4.15 for directory traversal vulnerability -# The patch is relevant for building docs -patch -p1 < $CWD/CVE_2007_4559.patch - -python3 setup.py install --root=$PKG - -find $PKG -print0 | xargs -0 file | grep -e "executable" -e "shared object" | grep ELF \ - | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true - -mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION -cp -a LICENSE README.rst $PKG/usr/doc/$PRGNAM-$VERSION -cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild - -mkdir -p $PKG/install -cat $CWD/slack-desc > $PKG/install/slack-desc - -cd $PKG -/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE diff --git a/python/pywayland/pywayland.info b/python/pywayland/pywayland.info deleted file mode 100644 index 18b6feb7a0ff8..0000000000000 --- a/python/pywayland/pywayland.info +++ /dev/null @@ -1,10 +0,0 @@ -PRGNAM="pywayland" -VERSION="0.4.14" -HOMEPAGE="https://github.com/flacjacket/pywayland" -DOWNLOAD="https://github.com/flacjacket/pywayland/archive/v0.4.14/pywayland-0.4.14.tar.gz" -MD5SUM="bd14adba219986be14f58e4ca9eaa2b5" -DOWNLOAD_x86_64="" -MD5SUM_x86_64="" -REQUIRES="" -MAINTAINER="Isaac Yu" -EMAIL="isaacyu1@isaacyu1.com" diff --git a/python/pywayland/slack-desc b/python/pywayland/slack-desc deleted file mode 100644 index b75a19f372f1e..0000000000000 --- a/python/pywayland/slack-desc +++ /dev/null @@ -1,19 +0,0 @@ -# HOW TO EDIT THIS FILE: -# The "handy ruler" below makes it easier to edit a package description. -# Line up the first '|' above the ':' following the base package name, and -# the '|' on the right side marks the last column you can put a character in. -# You must make exactly 11 lines for the formatting to be correct. It's also -# customary to leave one space after the ':' except on otherwise blank lines. - - |-----handy-ruler------------------------------------------------------| -pywayland: pywayland (Python bindings for the libwayland library) -pywayland: -pywayland: PyWayland provides a wrapper to the libwayland library using the CFFI -pywayland: library to provide access to the Wayland library calls and written in -pywayland: pure Python. -pywayland: -pywayland: -pywayland: -pywayland: -pywayland: -pywayland: |