Sync from SUSE:SLFO:Main python-websockify revision 0c28e5fe0412ec6502ce819fc2163f1d

This commit is contained in:
Adrian Schröter 2024-05-03 23:30:54 +02:00
commit 95060a5926
5 changed files with 348 additions and 0 deletions

23
.gitattributes vendored Normal file
View File

@ -0,0 +1,23 @@
## Default LFS
*.7z filter=lfs diff=lfs merge=lfs -text
*.bsp filter=lfs diff=lfs merge=lfs -text
*.bz2 filter=lfs diff=lfs merge=lfs -text
*.gem filter=lfs diff=lfs merge=lfs -text
*.gz filter=lfs diff=lfs merge=lfs -text
*.jar filter=lfs diff=lfs merge=lfs -text
*.lz filter=lfs diff=lfs merge=lfs -text
*.lzma filter=lfs diff=lfs merge=lfs -text
*.obscpio filter=lfs diff=lfs merge=lfs -text
*.oxt filter=lfs diff=lfs merge=lfs -text
*.pdf filter=lfs diff=lfs merge=lfs -text
*.png filter=lfs diff=lfs merge=lfs -text
*.rpm filter=lfs diff=lfs merge=lfs -text
*.tbz filter=lfs diff=lfs merge=lfs -text
*.tbz2 filter=lfs diff=lfs merge=lfs -text
*.tgz filter=lfs diff=lfs merge=lfs -text
*.ttf filter=lfs diff=lfs merge=lfs -text
*.txz filter=lfs diff=lfs merge=lfs -text
*.whl filter=lfs diff=lfs merge=lfs -text
*.xz filter=lfs diff=lfs merge=lfs -text
*.zip filter=lfs diff=lfs merge=lfs -text
*.zst filter=lfs diff=lfs merge=lfs -text

10
optional-websockify.patch Normal file
View File

@ -0,0 +1,10 @@
--- websockify-0.10.0/setup.py
+++ websockify-0.10.0/setup.py
@@ -29,7 +29,6 @@
packages=['websockify'],
include_package_data=True,
- install_requires=['numpy'],
zip_safe=False,
entry_points={
'console_scripts': [

211
python-websockify.changes Normal file
View File

@ -0,0 +1,211 @@
-------------------------------------------------------------------
Tue Jun 7 11:54:41 UTC 2022 - Dirk Müller <dmueller@suse.com>
- add optional-websockify.patch to make dependency on numpy optional
-------------------------------------------------------------------
Mon Nov 8 19:53:48 UTC 2021 - Dirk Müller <dmueller@suse.com>
- build websockify for all flavors
-------------------------------------------------------------------
Fri Aug 27 11:25:10 UTC 2021 - pgajdos@suse.com
- version update to 0.10.0
* Python 3.4 or newer is now required
* Empty message frames are now supported
* Tokens can now specify a Unix domain socket file to connect to
* Time limits on JWT tokens are now respected
* Whitespace is better tolerated in token files
* Lots of minor fixes...
-------------------------------------------------------------------
Mon Jun 21 08:57:56 UTC 2021 - Michael Ströder <michael@stroeder.com>
- disable test test_asymmetric_jwe_token_plugin because of new algorithms
in jwcrypto 0.9.0+
-------------------------------------------------------------------
Mon Dec 14 21:26:47 UTC 2020 - Benjamin Greiner <code@bnavigator.de>
- This package depends on python-mox3 from openstack, which is only
available for the default python3 flavor. As a consequence,
also only build for the primary python3-flavor.
gh#openSUSE/python-rpm-macros#66
-------------------------------------------------------------------
Tue Jun 2 06:37:21 UTC 2020 - Marketa Calabkova <mcalabkova@suse.com>
- Replace nose with pytest
-------------------------------------------------------------------
Thu Mar 12 07:47:53 UTC 2020 - Tomáš Chvátal <tchvatal@suse.com>
- Fix buid without python2
-------------------------------------------------------------------
Mon Aug 19 08:56:31 UTC 2019 - Tomáš Chvátal <tchvatal@suse.com>
- Update to 0.9.0:
* Base64 support removed and binary mode is now required
* Low level WebSocket protocol handling now has its own class
* Authentication now optionally required for web server
* Server hostname can be used as the token
* JWT/JWS/JWE can be used for the token
* redis can be used for the token
* Can now log to syslog
* Improved latency by disabling Nagle for proxied connection
* Added client certificate authentication
* Support for password protected certificate key file
* TLS ciphers and options are now configurable
* Can be invoked via inetd
* Lots of minor fixes...
- Remove upstream merged:
* u_added_jwt_tokens_capability.patch
* u_Add-support-for-inetd.patch
* u_Fix-inetd-mode-on-python-2.patch
* fix-tests-py3.6.patch
- Drop suse specific PyJWT-token-plugin.patch, will be easier
to actually pull in new dependency on jwcrypto if needed
* The tests were failing when using PyJWT...
-------------------------------------------------------------------
Mon Apr 8 14:33:03 UTC 2019 - Cédric Bosdonnat <cbosdonnat@suse.com>
- Fix PyJWT / jwcrypto dependency problem (boo#1131024)
-------------------------------------------------------------------
Wed Feb 13 09:25:56 UTC 2019 - Tomáš Chvátal <tchvatal@suse.com>
- Execute tests
- Switch to github tarball to get tests
- Add patch to fix tests on python 3.6+:
* fix-tests-py3.6.patch
-------------------------------------------------------------------
Tue Feb 12 14:34:16 UTC 2019 - Cédric Bosdonnat <cbosdonnat@suse.com>
- Add JWT token plugin feature.
Added patches:
u_added_jwt_tokens_capability.patch
PyJWT-token-plugin.patch: fate#325762
-------------------------------------------------------------------
Tue Dec 4 12:56:00 UTC 2018 - Matej Cepl <mcepl@suse.com>
- Remove superfluous devel dependency for noarch package
-------------------------------------------------------------------
Mon Oct 2 21:43:19 UTC 2017 - jengelh@inai.de
- Improve summaries.
-------------------------------------------------------------------
Mon Sep 25 08:37:21 UTC 2017 - msrb@suse.com
- add u_Add-support-for-inetd.patch: fate#323880
- add u_Fix-inetd-mode-on-python-2.patch: fate#323880
-------------------------------------------------------------------
Fri Aug 25 09:42:56 UTC 2017 - tbechtold@suse.com
- use https for Source
-------------------------------------------------------------------
Fri Aug 25 07:57:23 UTC 2017 - tbechtold@suse.com
- convert to singlespec
- split data files into -common package
-------------------------------------------------------------------
Sat Jul 22 08:19:00 UTC 2017 - dmueller@suse.com
- drop dependency on pyOpenSSL, seems unused (bsc#1049987)
-------------------------------------------------------------------
Mon May 2 20:48:32 UTC 2016 - dmueller@suse.com
- update to 0.8.0:
* Make websockify properly terminate children on SIGTERM (#226)
* Remove logging in signal handlers (this can cause Python to hang under certain conditions) (#219)
* Make it easier to log to a file (#205)
* Add support for IPv6 addresses in tokens in the TokenFile token plugins (#197)
* Improve auth plugin framework to enable better support for HTTP auth (#194, #201)
* Fix bug in JSONTokenAPI token plugin (#192)
* Fix a missing variable in the exception handler (#178)
* Python 3 support fixes (#140, #155, #159)
* Generic token-parsing plugins support (#162)
* Generic authentication plugins support (#172)
* Fixed frame corruption on big-endian systems (#161)
* Support heartbeats (via PING) and automatic responses to PONG (#169)
* Automatically reject unmasked client frames by default (strict mode) (#174)
* Automatically restart interrupted select calls (#175)
* Make 'run' respect environment settings (including virtualenv) (#176)
-------------------------------------------------------------------
Mon Oct 5 08:04:04 UTC 2015 - hguo@suse.com
- Add missing dependency on python-setuptools
-------------------------------------------------------------------
Sat Jul 25 10:48:31 UTC 2015 - seife+obs@b1-systems.com
- fix non-SUSE build by conditionalizing "Recommends:" tag
-------------------------------------------------------------------
Thu May 14 13:45:46 UTC 2015 - benoit.monin@gmx.fr
- update to version 0.6.1:
* PATCH RELEASE: Fixes a bug causing file_only to not be passed
properly
- switch archive to zip (tar.gz not available on pypi)
- add unzip as BuildRequires
- remove unwanted shebang in python files
- drop unneeded executable bit of web_socket.js
-------------------------------------------------------------------
Tue Sep 16 13:30:59 UTC 2014 - tbechtold@suse.com
- update to version 0.6.0:
* **NOTE** : 0.6.0 will break existing code that sub-classes WebsocketProxy
* Refactor to use standard SocketServer RequestHandler design
* Fix zombie process bug on certain systems when using multiprocessing
* Add better unit tests
* Log information via python `logging` module
-------------------------------------------------------------------
Thu Oct 24 11:17:04 UTC 2013 - speilicke@suse.com
- Require python-setuptools instead of distribute (upstreams merged)
-------------------------------------------------------------------
Wed Jul 3 11:53:13 UTC 2013 - dmueller@suse.com
- update to 0.5.1:
* use upstream einaros/ws (>=0.4.27) with websockify.js
* file_only and no_parent security options for WSRequestHandler
* Update build of web-socket-js (c0855c6cae)
* add include/web-socket-js-project submodule to gimite/web-socket-js
for DSFG compliance.
* drop Hixie protocol support
-------------------------------------------------------------------
Mon Apr 29 12:13:27 UTC 2013 - dmueller@suse.com
- update to 0.4.1:
* add include/ directory and remove some dev files from source
distribution.
* use Buffer base64 support in Node.js implementation
-------------------------------------------------------------------
Fri Jan 18 10:00:42 UTC 2013 - cfarrell@suse.com
- license update: LGPL-3.0 and MPL-2.0 and BSD-2-Clause and BSD-3-Clause
See LICENSE.txt
-------------------------------------------------------------------
Thu Jan 17 14:43:51 UTC 2013 - saschpe@suse.de
- Initial version

101
python-websockify.spec Normal file
View File

@ -0,0 +1,101 @@
#
# spec file for package python-websockify
#
# Copyright (c) 2022 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via https://bugs.opensuse.org/
#
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
Name: python-websockify
Version: 0.10.0
Release: 0
Summary: WebSocket to TCP proxy/bridge
License: BSD-2-Clause AND LGPL-3.0-only AND MPL-2.0 AND BSD-3-Clause
URL: https://github.com/novnc/websockify
Source: https://github.com/novnc/websockify/archive/v%{version}.tar.gz
Patch1: optional-websockify.patch
BuildRequires: %{python_module cryptography}
BuildRequires: %{python_module jwcrypto}
BuildRequires: %{python_module pytest}
BuildRequires: %{python_module redis}
BuildRequires: %{python_module setuptools}
BuildRequires: %{python_module simplejson}
BuildRequires: fdupes
BuildRequires: python-rpm-macros
BuildRequires: %{python_module numpy if (%python-base without python36-base)}
Requires: python-setuptools
Requires(post): update-alternatives
Requires(postun):update-alternatives
BuildArch: noarch
%if 0%{?suse_version}
Recommends: python-jwcrypto
Recommends: python-numpy
Recommends: python-redis
Recommends: python-simplejson
%endif
%python_subpackages
%description
websockify was formerly named wsproxy and was part of the
noVNC project.
At the most basic level, websockify just translates WebSockets traffic
to normal socket traffic. Websockify accepts the WebSockets handshake,
parses it, and then begins forwarding traffic between the client and
the target in both directions.
%package -n python-websockify-common
Summary: Common data files for the Websockify TCP proxy/bridge
Provides: %{python_module websockify-common = %{version}}
%description -n python-websockify-common
websockify was formerly named wsproxy and was part of the
noVNC project.
At the most basic level, websockify just translates WebSockets traffic
to normal socket traffic. Websockify accepts the WebSockets handshake,
parses it, and then begins forwarding traffic between the client and
the target in both directions.
This package contains common files.
%prep
%autosetup -p1 -n websockify-%{version}
# remove unwanted shebang
sed -i '1 { /^#!/ d }' websockify/websock*.py
%build
%python_build
%install
%python_install
%python_expand %fdupes %{buildroot}%{$python_sitelib}
%python_clone -a %{buildroot}%{_bindir}/websockify
%check
%pytest -k 'not test_asymmetric_jwe_token_plugin'
%post
%python_install_alternative websockify
%postun
%python_uninstall_alternative websockify
%files %{python_files}
%license COPYING
%doc CHANGES.txt README.md
%python_alternative %{_bindir}/websockify
%{python_sitelib}/*
%changelog

BIN
v0.10.0.tar.gz (Stored with Git LFS) Normal file

Binary file not shown.