Merge branch 'openwrt:master' into master

This commit is contained in:
Hayzam Sherif 2023-04-18 21:55:57 +05:30 committed by GitHub
commit 7dc9d9b314
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
21 changed files with 180 additions and 406 deletions

View file

@ -6,7 +6,7 @@
include $(TOPDIR)/rules.mk include $(TOPDIR)/rules.mk
PKG_NAME:=php PKG_NAME:=php
PKG_VERSION:=8.2.3 PKG_VERSION:=8.2.5
PKG_RELEASE:=1 PKG_RELEASE:=1
PKG_MAINTAINER:=Michael Heimpold <mhei@heimpold.de> PKG_MAINTAINER:=Michael Heimpold <mhei@heimpold.de>
@ -16,7 +16,7 @@ PKG_CPE_ID:=cpe:/a:php:php
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz
PKG_SOURCE_URL:=http://www.php.net/distributions/ PKG_SOURCE_URL:=http://www.php.net/distributions/
PKG_HASH:=b9b566686e351125d67568a33291650eb8dfa26614d205d70d82e6e92613d457 PKG_HASH:=800738c359b7f1e67e40c22713d2d90276bc85ba1c21b43d99edd43c254c5f76
PKG_BUILD_PARALLEL:=1 PKG_BUILD_PARALLEL:=1
PKG_BUILD_FLAGS:=no-mips16 PKG_BUILD_FLAGS:=no-mips16

View file

@ -9,7 +9,7 @@ Make generated php_config.h constant across rebuilds.
--- a/configure.ac --- a/configure.ac
+++ b/configure.ac +++ b/configure.ac
@@ -1440,7 +1440,7 @@ PHP_REMOVE_USR_LIB(LDFLAGS) @@ -1441,7 +1441,7 @@ PHP_REMOVE_USR_LIB(LDFLAGS)
EXTRA_LDFLAGS="$EXTRA_LDFLAGS $PHP_LDFLAGS" EXTRA_LDFLAGS="$EXTRA_LDFLAGS $PHP_LDFLAGS"
EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $PHP_LDFLAGS" EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $PHP_LDFLAGS"

View file

@ -11,7 +11,7 @@
--- a/configure.ac --- a/configure.ac
+++ b/configure.ac +++ b/configure.ac
@@ -1623,13 +1623,13 @@ CFLAGS_CLEAN="$CFLAGS \$(PROF_FLAGS)" @@ -1624,13 +1624,13 @@ CFLAGS_CLEAN="$CFLAGS \$(PROF_FLAGS)"
CFLAGS="\$(CFLAGS_CLEAN) $standard_libtool_flag" CFLAGS="\$(CFLAGS_CLEAN) $standard_libtool_flag"
CXXFLAGS="$CXXFLAGS $standard_libtool_flag \$(PROF_FLAGS)" CXXFLAGS="$CXXFLAGS $standard_libtool_flag \$(PROF_FLAGS)"

View file

@ -8,11 +8,11 @@
include $(TOPDIR)/rules.mk include $(TOPDIR)/rules.mk
PKG_NAME:=python-cython PKG_NAME:=python-cython
PKG_VERSION:=0.29.33 PKG_VERSION:=0.29.34
PKG_RELEASE:=1 PKG_RELEASE:=1
PYPI_NAME:=Cython PYPI_NAME:=Cython
PKG_HASH:=5040764c4a4d2ce964a395da24f0d1ae58144995dab92c6b96f44c3f4d72286a PKG_HASH:=1909688f5d7b521a60c396d20bba9e47a1b2d2784bfb085401e1e1e7d29a29a8
PKG_LICENSE:=Apache-2.0 PKG_LICENSE:=Apache-2.0
PKG_LICENSE_FILES:=LICENSE.txt PKG_LICENSE_FILES:=LICENSE.txt

View file

@ -11,13 +11,13 @@
include $(TOPDIR)/rules.mk include $(TOPDIR)/rules.mk
PKG_NAME:=boost PKG_NAME:=boost
PKG_VERSION:=1.81.0 PKG_VERSION:=1.82.0
PKG_SOURCE_VERSION:=1_81_0 PKG_SOURCE_VERSION:=1_82_0
PKG_RELEASE:=1 PKG_RELEASE:=1
PKG_SOURCE:=$(PKG_NAME)_$(PKG_SOURCE_VERSION).tar.bz2 PKG_SOURCE:=$(PKG_NAME)_$(PKG_SOURCE_VERSION).tar.bz2
PKG_SOURCE_URL:=@SF/$(PKG_NAME)/$(PKG_NAME)/$(PKG_VERSION) https://boostorg.jfrog.io/artifactory/main/release/$(PKG_VERSION)/source/ PKG_SOURCE_URL:=@SF/$(PKG_NAME)/$(PKG_NAME)/$(PKG_VERSION) https://boostorg.jfrog.io/artifactory/main/release/$(PKG_VERSION)/source/
PKG_HASH:=71feeed900fbccca04a3b4f2f84a7c217186f28a940ed8b7ed4725986baf99fa PKG_HASH:=a6e1ab9b0860e6a2881dd7b21fe9f737a095e5f33a3a874afc6a345228597ee6
PKG_MAINTAINER:=Carlos M. Ferreira <carlosmf.pt@gmail.com> PKG_MAINTAINER:=Carlos M. Ferreira <carlosmf.pt@gmail.com>
PKG_LICENSE:=BSL-1.0 PKG_LICENSE:=BSL-1.0
@ -42,7 +42,7 @@ define Package/boost/Default
endef endef
define Package/boost/description define Package/boost/description
This package provides the Boost v1.81.0 libraries. This package provides the Boost v1.82.0 libraries.
Boost is a set of free, peer-reviewed, portable C++ source libraries. Boost is a set of free, peer-reviewed, portable C++ source libraries.
This package provides the following run-time libraries: This package provides the following run-time libraries:
@ -74,11 +74,11 @@ This package provides the following run-time libraries:
- thread - thread
- timer - timer
- type_erasure - type_erasure
- url (new) - url
- wave - wave
There are many more header-only libraries supported by Boost. There are many more header-only libraries supported by Boost.
See more at http://www.boost.org/doc/libs/1_81_0/ See more at http://www.boost.org/doc/libs/1_82_0/
endef endef
PKG_BUILD_DEPENDS:=boost/host PKG_BUILD_DEPENDS:=boost/host

View file

@ -1,7 +1,7 @@
# #
# Copyright (C) 2006-2011 Openwrt.org # Copyright (C) 2006-2011 Openwrt.org
# Copyright (C) 2011 SMBPhone Inc. # Copyright (C) 2011 SMBPhone Inc.
# Copyright (C) 2019 Jeffery To # Copyright (C) 2019, 2023 Jeffery To
# #
# This is free software, licensed under the GNU General Public License v2. # This is free software, licensed under the GNU General Public License v2.
# See /LICENSE for more information. # See /LICENSE for more information.
@ -10,13 +10,13 @@
include $(TOPDIR)/rules.mk include $(TOPDIR)/rules.mk
PKG_NAME:=slang PKG_NAME:=slang
PKG_VERSION:=2.3.2 PKG_VERSION:=2.3.3
PKG_RELEASE:=5 PKG_RELEASE:=1
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
PKG_SOURCE_URL:=https://www.jedsoft.org/releases/slang \ PKG_SOURCE_URL:=https://www.jedsoft.org/releases/slang \
https://www.jedsoft.org/releases/slang/old https://www.jedsoft.org/releases/slang/old
PKG_HASH:=fc9e3b0fc4f67c3c1f6d43c90c16a5c42d117b8e28457c5b46831b8b5d3ae31a PKG_HASH:=f9145054ae131973c61208ea82486d5dd10e3c5cdad23b7c4a0617743c8f5a18
PKG_LICENSE:=GPL-2.0-or-later PKG_LICENSE:=GPL-2.0-or-later
PKG_LICENSE_FILES:=COPYING PKG_LICENSE_FILES:=COPYING

View file

@ -1,6 +1,6 @@
--- a/configure --- a/configure
+++ b/configure +++ b/configure
@@ -7029,7 +7029,7 @@ TERMCAP=-ltermcap @@ -6987,7 +6987,7 @@ TERMCAP=-ltermcap
for terminfo_dir in $JD_Terminfo_Dirs for terminfo_dir in $JD_Terminfo_Dirs
do do

View file

@ -1,12 +1,12 @@
include $(TOPDIR)/rules.mk include $(TOPDIR)/rules.mk
PKG_NAME:=dnsdist PKG_NAME:=dnsdist
PKG_VERSION:=1.7.3 PKG_VERSION:=1.8.0
PKG_RELEASE:=$(AUTORELEASE) PKG_RELEASE:=1
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
PKG_SOURCE_URL:=https://downloads.powerdns.com/releases/ PKG_SOURCE_URL:=https://downloads.powerdns.com/releases/
PKG_HASH:=7eaf6fac2f26565c5d8658d42a213799e05f4d3bc68e7c716e7174df41315886 PKG_HASH:=1c0d375c25453d349b88e03ff589aa2603ca8692fc98364c068ead372804704f
PKG_MAINTAINER:=Peter van Dijk <peter.van.dijk@powerdns.com> PKG_MAINTAINER:=Peter van Dijk <peter.van.dijk@powerdns.com>
PKG_LICENSE:=GPL-2.0-only PKG_LICENSE:=GPL-2.0-only

View file

@ -11,12 +11,12 @@
include $(TOPDIR)/rules.mk include $(TOPDIR)/rules.mk
PKG_NAME:=knxd PKG_NAME:=knxd
PKG_VERSION:=0.14.56 PKG_VERSION:=0.14.58
PKG_RELEASE:=1 PKG_RELEASE:=1
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
PKG_SOURCE_URL:=https://codeload.github.com/knxd/knxd/tar.gz/$(PKG_VERSION)? PKG_SOURCE_URL:=https://codeload.github.com/knxd/knxd/tar.gz/$(PKG_VERSION)?
PKG_HASH:=ae447870d0aba55062cbca8acdaa7a40578ad3ef6e6fb3a91dc982f5d81d5da9 PKG_HASH:=4c58ca24c3b382649356b8d794453927f0722739eb5ca654a1bd8de0006b0404
PKG_MAINTAINER:=Othmar Truniger <github@truniger.ch> PKG_MAINTAINER:=Othmar Truniger <github@truniger.ch>
PKG_LICENSE:=GPL-2.0-or-later PKG_LICENSE:=GPL-2.0-or-later

View file

@ -7,4 +7,4 @@
-test -d .git || exit -test -d .git || exit
-# git describe --tags -# git describe --tags
-git log --format=format:%D | perl -ne 'next unless s#.*tag: ##; s#,.*##; next if m#/#; print; exit;' -git log --format=format:%D | perl -ne 'next unless s#.*tag: ##; s#,.*##; next if m#/#; print; exit;'
+echo -n "0.14.56" +echo -n "0.14.58"

View file

@ -13,15 +13,15 @@
include $(TOPDIR)/rules.mk include $(TOPDIR)/rules.mk
PKG_NAME:=nmap PKG_NAME:=nmap
PKG_VERSION:=7.91 PKG_VERSION:=7.93
PKG_RELEASE:=$(AUTORELEASE) PKG_RELEASE:=1
PKG_MAINTAINER:=Nuno Goncalves <nunojpg@gmail.com> PKG_MAINTAINER:=Nuno Gonçalves <nunojpg@gmail.com>
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
PKG_SOURCE_URL:=https://nmap.org/dist/ PKG_SOURCE_URL:=https://nmap.org/dist/
PKG_HASH:=18cc4b5070511c51eb243cdd2b0b30ff9b2c4dc4544c6312f75ce3a67a593300 PKG_HASH:=55bcfe4793e25acc96ba4274d8c4228db550b8e8efd72004b38ec55a2dd16651
PKG_LICENSE:=GPL-2.0-only PKG_LICENSE:=NPSL-0.94-or-NPSL-0.95
PKG_LICENSE_FILES:=COPYING PKG_LICENSE_FILES:=LICENSE
PKG_CPE_ID:=cpe:/a:nmap:nmap PKG_CPE_ID:=cpe:/a:nmap:nmap
PKG_BUILD_PARALLEL:=1 PKG_BUILD_PARALLEL:=1

View file

@ -86,7 +86,7 @@ Resolves: #1484
# Ndiff # Ndiff
# #
@@ -26,11 +26,11 @@ xml.__path__ = [x for x in xml.__path__ @@ -25,11 +25,11 @@ xml.__path__ = [x for x in xml.__path__
import xml.sax import xml.sax
import xml.sax.saxutils import xml.sax.saxutils
import xml.dom.minidom import xml.dom.minidom
@ -100,7 +100,7 @@ Resolves: #1484
class OverrideEntityResolver(xml.sax.handler.EntityResolver): class OverrideEntityResolver(xml.sax.handler.EntityResolver):
@@ -75,35 +75,35 @@ class Scan(object): @@ -74,35 +74,35 @@ class Scan(object):
def write_nmaprun_open(self, writer): def write_nmaprun_open(self, writer):
attrs = {} attrs = {}
if self.scanner is not None: if self.scanner is not None:
@ -149,7 +149,7 @@ Resolves: #1484
frag.appendChild(elem) frag.appendChild(elem)
return frag return frag
@@ -133,17 +133,17 @@ class Host(object): @@ -132,17 +132,17 @@ class Host(object):
def format_name(self): def format_name(self):
"""Return a human-readable identifier for this host.""" """Return a human-readable identifier for this host."""
@ -171,7 +171,7 @@ Resolves: #1484
def add_port(self, port): def add_port(self, port):
self.ports[port.spec] = port self.ports[port.spec] = port
@@ -160,46 +160,46 @@ class Host(object): @@ -159,46 +159,46 @@ class Host(object):
return state is None or state in self.extraports return state is None or state in self.extraports
def extraports_string(self): def extraports_string(self):
@ -233,7 +233,7 @@ Resolves: #1484
if self.state is not None: if self.state is not None:
elem.appendChild(self.state_to_dom_fragment(document)) elem.appendChild(self.state_to_dom_fragment(document))
@@ -208,13 +208,13 @@ class Host(object): @@ -207,13 +207,13 @@ class Host(object):
elem.appendChild(addr.to_dom_fragment(document)) elem.appendChild(addr.to_dom_fragment(document))
if len(self.hostnames) > 0: if len(self.hostnames) > 0:
@ -249,7 +249,7 @@ Resolves: #1484
ports_elem.appendChild(self.extraports_to_dom_fragment(document)) ports_elem.appendChild(self.extraports_to_dom_fragment(document))
for port in sorted(self.ports.values()): for port in sorted(self.ports.values()):
if not self.is_extraports(port.state): if not self.is_extraports(port.state):
@@ -223,13 +223,13 @@ class Host(object): @@ -222,13 +222,13 @@ class Host(object):
elem.appendChild(ports_elem) elem.appendChild(ports_elem)
if len(self.os) > 0: if len(self.os) > 0:
@ -265,7 +265,7 @@ Resolves: #1484
for sr in self.script_results: for sr in self.script_results:
hostscript_elem.appendChild(sr.to_dom_fragment(document)) hostscript_elem.appendChild(sr.to_dom_fragment(document))
elem.appendChild(hostscript_elem) elem.appendChild(hostscript_elem)
@@ -243,7 +243,7 @@ class Address(object): @@ -242,7 +242,7 @@ class Address(object):
self.s = s self.s = s
def __eq__(self, other): def __eq__(self, other):
@ -274,7 +274,7 @@ Resolves: #1484
def __ne__(self, other): def __ne__(self, other):
return not self.__eq__(other) return not self.__eq__(other)
@@ -251,8 +251,8 @@ class Address(object): @@ -250,8 +250,8 @@ class Address(object):
def __hash__(self): def __hash__(self):
return hash(self.sort_key()) return hash(self.sort_key())
@ -285,7 +285,7 @@ Resolves: #1484
def __str__(self): def __str__(self):
return str(self.s) return str(self.s)
@@ -261,21 +261,21 @@ class Address(object): @@ -260,21 +260,21 @@ class Address(object):
return self.s return self.s
def new(type, s): def new(type, s):
@ -314,7 +314,7 @@ Resolves: #1484
frag.appendChild(elem) frag.appendChild(elem)
return frag return frag
@@ -284,21 +284,21 @@ class Address(object): @@ -283,21 +283,21 @@ class Address(object):
class IPv4Address(Address): class IPv4Address(Address):
@ -339,7 +339,7 @@ Resolves: #1484
def sort_key(self): def sort_key(self):
return (2, self.s) return (2, self.s)
@@ -317,31 +317,28 @@ class Port(object): @@ -316,31 +316,28 @@ class Port(object):
def state_string(self): def state_string(self):
if self.state is None: if self.state is None:
@ -382,7 +382,7 @@ Resolves: #1484
elem.appendChild(state_elem) elem.appendChild(state_elem)
elem.appendChild(self.service.to_dom_fragment(document)) elem.appendChild(self.service.to_dom_fragment(document))
for sr in self.script_results: for sr in self.script_results:
@@ -385,7 +382,7 @@ class Service(object): @@ -384,7 +381,7 @@ class Service(object):
if len(parts) == 0: if len(parts) == 0:
return None return None
else: else:
@ -391,7 +391,7 @@ Resolves: #1484
def version_string(self): def version_string(self):
"""Get a string like in the VERSION column of Nmap output.""" """Get a string like in the VERSION column of Nmap output."""
@@ -395,17 +392,17 @@ class Service(object): @@ -394,17 +391,17 @@ class Service(object):
if self.version is not None: if self.version is not None:
parts.append(self.version) parts.append(self.version)
if self.extrainfo is not None: if self.extrainfo is not None:
@ -413,7 +413,7 @@ Resolves: #1484
v = getattr(self, attr) v = getattr(self, attr)
if v is None: if v is None:
continue continue
@@ -435,53 +432,53 @@ class ScriptResult(object): @@ -434,53 +431,53 @@ class ScriptResult(object):
result = [] result = []
lines = self.output.splitlines() lines = self.output.splitlines()
if len(lines) > 0: if len(lines) > 0:
@ -485,7 +485,7 @@ Resolves: #1484
def script_result_diffs_to_dom_fragment(elem, script_results_a, def script_result_diffs_to_dom_fragment(elem, script_results_a,
@@ -489,13 +486,13 @@ def script_result_diffs_to_dom_fragment( @@ -488,13 +485,13 @@ def script_result_diffs_to_dom_fragment(
if len(script_results_a) == 0 and len(script_results_b) == 0: if len(script_results_a) == 0 and len(script_results_b) == 0:
return document.createDocumentFragment() return document.createDocumentFragment()
elif len(script_results_b) == 0: elif len(script_results_b) == 0:
@ -501,7 +501,7 @@ Resolves: #1484
for sr in script_results_b: for sr in script_results_b:
elem.appendChild(sr.to_dom_fragment(document)) elem.appendChild(sr.to_dom_fragment(document))
b_elem.appendChild(elem) b_elem.appendChild(elem)
@@ -580,10 +577,10 @@ class ScanDiffText(ScanDiff): @@ -579,10 +576,10 @@ class ScanDiffText(ScanDiff):
banner_a = format_banner(self.scan_a) banner_a = format_banner(self.scan_a)
banner_b = format_banner(self.scan_b) banner_b = format_banner(self.scan_b)
if banner_a != banner_b: if banner_a != banner_b:
@ -515,7 +515,7 @@ Resolves: #1484
def output_pre_scripts(self, pre_script_result_diffs): def output_pre_scripts(self, pre_script_result_diffs):
print_script_result_diffs_text("Pre-scan script results", print_script_result_diffs_text("Pre-scan script results",
@@ -596,7 +593,7 @@ class ScanDiffText(ScanDiff): @@ -595,7 +592,7 @@ class ScanDiffText(ScanDiff):
post_script_result_diffs, self.f) post_script_result_diffs, self.f)
def output_host_diff(self, h_diff): def output_host_diff(self, h_diff):
@ -524,7 +524,7 @@ Resolves: #1484
h_diff.print_text(self.f) h_diff.print_text(self.f)
def output_ending(self): def output_ending(self):
@@ -621,8 +618,8 @@ class ScanDiffXML(ScanDiff): @@ -620,8 +617,8 @@ class ScanDiffXML(ScanDiff):
def output_beginning(self): def output_beginning(self):
self.writer.startDocument() self.writer.startDocument()
@ -535,7 +535,7 @@ Resolves: #1484
if self.nmaprun_differs(): if self.nmaprun_differs():
self.writer.frag_a( self.writer.frag_a(
@@ -635,7 +632,7 @@ class ScanDiffXML(ScanDiff): @@ -634,7 +631,7 @@ class ScanDiffXML(ScanDiff):
def output_pre_scripts(self, pre_script_result_diffs): def output_pre_scripts(self, pre_script_result_diffs):
if len(pre_script_result_diffs) > 0 or verbose: if len(pre_script_result_diffs) > 0 or verbose:
@ -544,7 +544,7 @@ Resolves: #1484
frag = script_result_diffs_to_dom_fragment( frag = script_result_diffs_to_dom_fragment(
prescript_elem, self.scan_a.pre_script_results, prescript_elem, self.scan_a.pre_script_results,
self.scan_b.pre_script_results, pre_script_result_diffs, self.scan_b.pre_script_results, pre_script_result_diffs,
@@ -645,7 +642,7 @@ class ScanDiffXML(ScanDiff): @@ -644,7 +641,7 @@ class ScanDiffXML(ScanDiff):
def output_post_scripts(self, post_script_result_diffs): def output_post_scripts(self, post_script_result_diffs):
if len(post_script_result_diffs) > 0 or verbose: if len(post_script_result_diffs) > 0 or verbose:
@ -553,7 +553,7 @@ Resolves: #1484
frag = script_result_diffs_to_dom_fragment( frag = script_result_diffs_to_dom_fragment(
postscript_elem, self.scan_a.post_script_results, postscript_elem, self.scan_a.post_script_results,
self.scan_b.post_script_results, post_script_result_diffs, self.scan_b.post_script_results, post_script_result_diffs,
@@ -659,8 +656,8 @@ class ScanDiffXML(ScanDiff): @@ -658,8 +655,8 @@ class ScanDiffXML(ScanDiff):
frag.unlink() frag.unlink()
def output_ending(self): def output_ending(self):
@ -564,7 +564,7 @@ Resolves: #1484
self.writer.endDocument() self.writer.endDocument()
@@ -718,9 +715,9 @@ class HostDiff(object): @@ -717,9 +714,9 @@ class HostDiff(object):
self.cost += os_cost self.cost += os_cost
extraports_a = tuple((count, state) extraports_a = tuple((count, state)
@ -576,7 +576,7 @@ Resolves: #1484
if extraports_a != extraports_b: if extraports_a != extraports_b:
self.extraports_changed = True self.extraports_changed = True
self.cost += 1 self.cost += 1
@@ -746,69 +743,69 @@ class HostDiff(object): @@ -745,69 +742,69 @@ class HostDiff(object):
# Names and addresses. # Names and addresses.
if self.id_changed: if self.id_changed:
if host_a.state is not None: if host_a.state is not None:
@ -667,7 +667,7 @@ Resolves: #1484
print_script_result_diffs_text("Host script results", print_script_result_diffs_text("Host script results",
host_a.script_results, host_b.script_results, host_a.script_results, host_b.script_results,
@@ -819,32 +816,32 @@ class HostDiff(object): @@ -818,32 +815,32 @@ class HostDiff(object):
host_b = self.host_b host_b = self.host_b
frag = document.createDocumentFragment() frag = document.createDocumentFragment()
@ -706,7 +706,7 @@ Resolves: #1484
b_elem.appendChild(host_b.state_to_dom_fragment(document)) b_elem.appendChild(host_b.state_to_dom_fragment(document))
host_elem.appendChild(b_elem) host_elem.appendChild(b_elem)
@@ -853,31 +850,31 @@ class HostDiff(object): @@ -852,31 +849,31 @@ class HostDiff(object):
addrset_b = set(host_b.addresses) addrset_b = set(host_b.addresses)
for addr in sorted(addrset_a.intersection(addrset_b)): for addr in sorted(addrset_a.intersection(addrset_b)):
host_elem.appendChild(addr.to_dom_fragment(document)) host_elem.appendChild(addr.to_dom_fragment(document))
@ -743,7 +743,7 @@ Resolves: #1484
for hostname in sorted(hostnameset_b - hostnameset_a): for hostname in sorted(hostnameset_b - hostnameset_a):
b_elem.appendChild( b_elem.appendChild(
host_b.hostname_to_dom_fragment(document, hostname)) host_b.hostname_to_dom_fragment(document, hostname))
@@ -886,15 +883,15 @@ class HostDiff(object): @@ -885,15 +882,15 @@ class HostDiff(object):
if hostnames_elem.hasChildNodes(): if hostnames_elem.hasChildNodes():
host_elem.appendChild(hostnames_elem) host_elem.appendChild(hostnames_elem)
@ -762,7 +762,7 @@ Resolves: #1484
b_elem.appendChild(host_b.extraports_to_dom_fragment(document)) b_elem.appendChild(host_b.extraports_to_dom_fragment(document))
ports_elem.appendChild(b_elem) ports_elem.appendChild(b_elem)
# Port list. # Port list.
@@ -910,18 +907,18 @@ class HostDiff(object): @@ -909,18 +906,18 @@ class HostDiff(object):
# OS changes. # OS changes.
if self.os_changed or verbose: if self.os_changed or verbose:
@ -784,7 +784,7 @@ Resolves: #1484
for i in range(j1, j2): for i in range(j1, j2):
b_elem.appendChild(host_b.os_to_dom_fragment( b_elem.appendChild(host_b.os_to_dom_fragment(
document, host_b.os[i])) document, host_b.os[i]))
@@ -935,7 +932,7 @@ class HostDiff(object): @@ -934,7 +931,7 @@ class HostDiff(object):
# Host script changes. # Host script changes.
if len(self.script_result_diffs) > 0 or verbose: if len(self.script_result_diffs) > 0 or verbose:
@ -793,7 +793,7 @@ Resolves: #1484
host_elem.appendChild(script_result_diffs_to_dom_fragment( host_elem.appendChild(script_result_diffs_to_dom_fragment(
hostscript_elem, host_a.script_results, hostscript_elem, host_a.script_results,
host_b.script_results, self.script_result_diffs, host_b.script_results, self.script_result_diffs,
@@ -988,38 +985,38 @@ class PortDiff(object): @@ -987,38 +984,38 @@ class PortDiff(object):
self.port_b.service.version_string()] self.port_b.service.version_string()]
if a_columns == b_columns: if a_columns == b_columns:
if verbose or self.script_result_diffs > 0: if verbose or self.script_result_diffs > 0:
@ -843,7 +843,7 @@ Resolves: #1484
b_elem.appendChild( b_elem.appendChild(
self.port_b.service.to_dom_fragment(document)) self.port_b.service.to_dom_fragment(document))
port_elem.appendChild(b_elem) port_elem.appendChild(b_elem)
@@ -1027,10 +1024,10 @@ class PortDiff(object): @@ -1026,10 +1023,10 @@ class PortDiff(object):
port_elem.appendChild(sr_diff.to_dom_fragment(document)) port_elem.appendChild(sr_diff.to_dom_fragment(document))
portdiff_elem.appendChild(port_elem) portdiff_elem.appendChild(port_elem)
else: else:
@ -856,7 +856,7 @@ Resolves: #1484
b_elem.appendChild(self.port_b.to_dom_fragment(document)) b_elem.appendChild(self.port_b.to_dom_fragment(document))
portdiff_elem.appendChild(b_elem) portdiff_elem.appendChild(b_elem)
@@ -1085,13 +1082,13 @@ class ScriptResultDiff(object): @@ -1084,13 +1081,13 @@ class ScriptResultDiff(object):
for op, i1, i2, j1, j2 in diffs.get_opcodes(): for op, i1, i2, j1, j2 in diffs.get_opcodes():
if op == "replace" or op == "delete": if op == "replace" or op == "delete":
for k in range(i1, i2): for k in range(i1, i2):
@ -873,7 +873,7 @@ Resolves: #1484
def to_dom_fragment(self, document): def to_dom_fragment(self, document):
frag = document.createDocumentFragment() frag = document.createDocumentFragment()
@@ -1101,11 +1098,11 @@ class ScriptResultDiff(object): @@ -1100,11 +1097,11 @@ class ScriptResultDiff(object):
frag.appendChild(self.sr_a.to_dom_fragment(document)) frag.appendChild(self.sr_a.to_dom_fragment(document))
else: else:
if self.sr_a is not None: if self.sr_a is not None:
@ -887,7 +887,7 @@ Resolves: #1484
b_elem.appendChild(self.sr_b.to_dom_fragment(document)) b_elem.appendChild(self.sr_b.to_dom_fragment(document))
frag.appendChild(b_elem) frag.appendChild(b_elem)
return frag return frag
@@ -1119,7 +1116,7 @@ class Table(object): @@ -1118,7 +1115,7 @@ class Table(object):
copied to the output.""" copied to the output."""
self.widths = [] self.widths = []
self.rows = [] self.rows = []
@ -896,7 +896,7 @@ Resolves: #1484
self.padding = [] self.padding = []
j = 0 j = 0
while j < len(template) and template[j] != "*": while j < len(template) and template[j] != "*":
@@ -1144,7 +1141,7 @@ class Table(object): @@ -1143,7 +1140,7 @@ class Table(object):
for i in range(len(row)): for i in range(len(row)):
if row[i] is None: if row[i] is None:
@ -905,7 +905,7 @@ Resolves: #1484
else: else:
s = str(row[i]) s = str(row[i])
if i == len(self.widths): if i == len(self.widths):
@@ -1166,7 +1163,7 @@ class Table(object): @@ -1165,7 +1162,7 @@ class Table(object):
for row in self.rows: for row in self.rows:
parts = [self.prefix] parts = [self.prefix]
i = 0 i = 0
@ -914,7 +914,7 @@ Resolves: #1484
# A raw string. # A raw string.
lines.append(row) lines.append(row)
else: else:
@@ -1175,13 +1172,13 @@ class Table(object): @@ -1174,13 +1171,13 @@ class Table(object):
if i < len(self.padding): if i < len(self.padding):
parts.append(self.padding[i]) parts.append(self.padding[i])
i += 1 i += 1
@ -931,7 +931,7 @@ Resolves: #1484
class NmapContentHandler(xml.sax.handler.ContentHandler): class NmapContentHandler(xml.sax.handler.ContentHandler):
@@ -1201,24 +1198,24 @@ class NmapContentHandler(xml.sax.handler @@ -1200,24 +1197,24 @@ class NmapContentHandler(xml.sax.handler
self.skip_over = False self.skip_over = False
self._start_elem_handlers = { self._start_elem_handlers = {
@ -972,7 +972,7 @@ Resolves: #1484
} }
def parent_element(self): def parent_element(self):
@@ -1248,72 +1245,72 @@ class NmapContentHandler(xml.sax.handler @@ -1247,72 +1244,72 @@ class NmapContentHandler(xml.sax.handler
def _start_nmaprun(self, name, attrs): def _start_nmaprun(self, name, attrs):
assert self.parent_element() is None assert self.parent_element() is None
if "start" in attrs: if "start" in attrs:
@ -1068,7 +1068,7 @@ Resolves: #1484
'attribute; assuming 0.' % ( 'attribute; assuming 0.' % (
name, self.current_host.format_name())) name, self.current_host.format_name()))
count = 0 count = 0
@@ -1321,99 +1318,99 @@ class NmapContentHandler(xml.sax.handler @@ -1320,99 +1317,99 @@ class NmapContentHandler(xml.sax.handler
try: try:
count = int(count) count = int(count)
except ValueError: except ValueError:
@ -1199,7 +1199,7 @@ Resolves: #1484
self.scan.end_date = datetime.datetime.fromtimestamp(end_timestamp) self.scan.end_date = datetime.datetime.fromtimestamp(end_timestamp)
def _end_host(self, name): def _end_host(self, name):
@@ -1435,23 +1432,23 @@ class XMLWriter (xml.sax.saxutils.XMLGen @@ -1434,23 +1431,23 @@ class XMLWriter (xml.sax.saxutils.XMLGen
def frag(self, frag): def frag(self, frag):
for node in frag.childNodes: for node in frag.childNodes:
@ -1231,7 +1231,7 @@ Resolves: #1484
Usage: %s [option] FILE1 FILE2 Usage: %s [option] FILE1 FILE2
Compare two Nmap XML files and display a list of their differences. Compare two Nmap XML files and display a list of their differences.
Differences include host state changes, port state changes, and changes to Differences include host state changes, port state changes, and changes to
@@ -1461,7 +1458,7 @@ service and OS detection. @@ -1460,7 +1457,7 @@ service and OS detection.
-v, --verbose also show hosts and ports that haven't changed. -v, --verbose also show hosts and ports that haven't changed.
--text display output in text format (default) --text display output in text format (default)
--xml display output in XML format\ --xml display output in XML format\
@ -1240,7 +1240,7 @@ Resolves: #1484
EXIT_EQUAL = 0 EXIT_EQUAL = 0
EXIT_DIFFERENT = 1 EXIT_DIFFERENT = 1
@@ -1469,8 +1466,8 @@ EXIT_ERROR = 2 @@ -1468,8 +1465,8 @@ EXIT_ERROR = 2
def usage_error(msg): def usage_error(msg):
@ -1251,7 +1251,7 @@ Resolves: #1484
sys.exit(EXIT_ERROR) sys.exit(EXIT_ERROR)
@@ -1481,7 +1478,7 @@ def main(): @@ -1480,7 +1477,7 @@ def main():
try: try:
opts, input_filenames = getopt.gnu_getopt( opts, input_filenames = getopt.gnu_getopt(
sys.argv[1:], "hv", ["help", "text", "verbose", "xml"]) sys.argv[1:], "hv", ["help", "text", "verbose", "xml"])
@ -1260,7 +1260,7 @@ Resolves: #1484
usage_error(e.msg) usage_error(e.msg)
for o, a in opts: for o, a in opts:
if o == "-h" or o == "--help": if o == "-h" or o == "--help":
@@ -1491,15 +1488,15 @@ def main(): @@ -1490,15 +1487,15 @@ def main():
verbose = True verbose = True
elif o == "--text": elif o == "--text":
if output_format is not None and output_format != "text": if output_format is not None and output_format != "text":
@ -1279,7 +1279,7 @@ Resolves: #1484
if output_format is None: if output_format is None:
output_format = "text" output_format = "text"
@@ -1512,8 +1509,8 @@ def main(): @@ -1511,8 +1508,8 @@ def main():
scan_a.load_from_file(filename_a) scan_a.load_from_file(filename_a)
scan_b = Scan() scan_b = Scan()
scan_b.load_from_file(filename_b) scan_b.load_from_file(filename_b)
@ -1508,7 +1508,7 @@ Resolves: #1484
# Ndiff # Ndiff
# #
@@ -67,15 +67,15 @@ if INSTALL_LIB is not None and is_secure @@ -66,15 +66,15 @@ if INSTALL_LIB is not None and is_secure
try: try:
import ndiff import ndiff

View file

@ -1,20 +0,0 @@
--- a/nmap_error.cc
+++ b/nmap_error.cc
@@ -66,6 +66,7 @@
#include "NmapOps.h"
#include "xml.h"
+#include <ctime>
#include <errno.h>
#if TIME_WITH_SYS_TIME
# include <sys/time.h>
--- a/nping/EchoServer.cc
+++ b/nping/EchoServer.cc
@@ -69,6 +69,7 @@
#include "NpingOps.h"
#include "ProbeMode.h"
#include <signal.h>
+#include <ctime>
extern NpingOps o;
extern EchoServer es;

View file

@ -1,5 +1,5 @@
# #
# Copyright (C) 2018 Jeffery To # Copyright (C) 2018-2019, 2022-2023 Jeffery To
# #
# This is free software, licensed under the GNU General Public License v2. # This is free software, licensed under the GNU General Public License v2.
# See /LICENSE for more information. # See /LICENSE for more information.
@ -8,12 +8,12 @@
include $(TOPDIR)/rules.mk include $(TOPDIR)/rules.mk
PKG_NAME:=obfs4proxy PKG_NAME:=obfs4proxy
PKG_VERSION:=0.0.13 PKG_VERSION:=0.0.14
PKG_RELEASE:=1 PKG_RELEASE:=1
PKG_SOURCE:=obfs4-$(PKG_NAME)-$(PKG_VERSION).tar.bz2 PKG_SOURCE:=obfs4-$(PKG_NAME)-$(PKG_VERSION).tar.bz2
PKG_SOURCE_URL:=https://gitlab.com/yawning/obfs4/-/archive/$(PKG_NAME)-$(PKG_VERSION)/ PKG_SOURCE_URL:=https://gitlab.com/yawning/obfs4/-/archive/$(PKG_NAME)-$(PKG_VERSION)/
PKG_HASH:=6b16f1e71f1b3d21f32d2fbd683203a3021fcb44e789aded12f98d92dad83bc9 PKG_HASH:=6ed94258433665a11a4631c6bbbb45b4452d65bdfbe4d30365a87b3d43a3a7ec
PKG_BUILD_DIR:=$(BUILD_DIR)/obfs4-$(PKG_NAME)-$(PKG_VERSION) PKG_BUILD_DIR:=$(BUILD_DIR)/obfs4-$(PKG_NAME)-$(PKG_VERSION)
PKG_LICENSE:=BSD-2-Clause GPL-3.0-or-later PKG_LICENSE:=BSD-2-Clause GPL-3.0-or-later

View file

@ -20,13 +20,13 @@ define Package/sshtunnel
SECTION:=net SECTION:=net
CATEGORY:=Network CATEGORY:=Network
SUBMENU:=SSH SUBMENU:=SSH
TITLE:=Manages Local and Remote openssh ssh(1) tunnels TITLE:=Manages local and remote openssh ssh(1) tunnels
DEPENDS:=+openssh-client DEPENDS:=+openssh-client
PKGARCH:=all PKGARCH:=all
endef endef
define Package/sshtunnel/description define Package/sshtunnel/description
Creates openssh ssh(1) Local and Remote tunnels configured in UCI file. Can be used to allow remote connections, possibly over NATed connections or without public IP/DNS Creates openssh ssh(1) local and remote tunnels configured in UCI file. Can be used to allow remote connections, possibly over NATed connections or without public IP/DNS
endef endef
define Package/sshtunnel/conffiles define Package/sshtunnel/conffiles

View file

@ -1,6 +1,6 @@
# #
# password authentication is not possible, public key authentication must be used. # Password authentication is not possible, public key authentication must be used.
# set "option IdentityFile" to he file from which the identity (private key) for RSA or DSA authentication is read. # Set "option IdentityFile" to the file from which the identity (private key) for RSA or DSA authentication is read.
# The default is ~/.ssh/identity for protocol version 1, and ~/.ssh/id_rsa and ~/.ssh/id_dsa for protocol version 2. # The default is ~/.ssh/identity for protocol version 1, and ~/.ssh/id_rsa and ~/.ssh/id_dsa for protocol version 2.
# ssh will also try to load certificate information from the filename obtained by appending -cert.pub to identity filenames. # ssh will also try to load certificate information from the filename obtained by appending -cert.pub to identity filenames.
# #
@ -33,7 +33,7 @@
# option localport 80 # option localport 80
# tunnelL(ocal) - when the connection will be initiated to the L(ocal) endpoint at # tunnelL(ocal) - when the connection will be initiated to the L(ocal) endpoint at
# localaddress:localport and then forwarded to remoteaddress:remoteport # localaddress:localport and then forwarded to remoteaddress:remoteport
# #
#config tunnelL test #config tunnelL test
# option server disney # option server disney

View file

@ -5,12 +5,12 @@
include $(TOPDIR)/rules.mk include $(TOPDIR)/rules.mk
PKG_NAME:=v2ray-core PKG_NAME:=v2ray-core
PKG_VERSION:=5.4.0 PKG_VERSION:=5.4.1
PKG_RELEASE:=1 PKG_RELEASE:=1
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
PKG_SOURCE_URL:=https://codeload.github.com/v2fly/v2ray-core/tar.gz/v$(PKG_VERSION)? PKG_SOURCE_URL:=https://codeload.github.com/v2fly/v2ray-core/tar.gz/v$(PKG_VERSION)?
PKG_HASH:=86be35461a9dc7d037e0045771d99f1eae284fdb7aa0818a6782d18b6b003fca PKG_HASH:=e208bca255c4689a30104e965039d73fa138a7a6e902f820cff94b5b772b042b
PKG_LICENSE:=MIT PKG_LICENSE:=MIT
PKG_LICENSE_FILES:=LICENSE PKG_LICENSE_FILES:=LICENSE

View file

@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk
PKG_NAME:=znc PKG_NAME:=znc
PKG_VERSION:=1.8.2 PKG_VERSION:=1.8.2
PKG_RELEASE:=$(AUTORELEASE) PKG_RELEASE:=6
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
PKG_SOURCE_URL:=https://znc.in/releases \ PKG_SOURCE_URL:=https://znc.in/releases \
@ -136,6 +136,77 @@ define webskin
ZNC_MODULES += znc-webskin-$(strip $(1)) ZNC_MODULES += znc-webskin-$(strip $(1))
endef endef
define playback
define Package/znc-mod-playback
$(Package/znc/default)
TITLE+= (playback plugin)
DEPENDS:=znc
endef
define Package/znc-mod-playback/description
Avoid repetitive playback buffers on re-connect with supported clients (e.g. mutter, colluquy)
endef
define Package/znc-mod-playback/install
$(INSTALL_DIR) $$(1)/usr/lib/znc/
$(INSTALL_BIN) $$(PKG_INSTALL_DIR)/usr/lib/znc/playback.so $$(1)/usr/lib/znc/
endef
ZNC_MODULES += znc-mod-playback
$(if $(CONFIG_PACKAGE_znc-mod-playback),ZNC_MODULE_TARGETS += playback.so)
endef
define Download/znc-playback
VERSION:=8dd128bfe2b24b2cc6a9ea2e2d28bfaa28d2a833
SUBDIR:=znc-mod-playback
FILE:=znc-playback-$$(VERSION).tar.xz
URL:=https://github.com/jpnurmi/znc-playback.git
MIRROR_HASH:=ac89d69048d62c5b15f39cc0d357a111ce4053816062e7bc1e553392b36fbd71
PROTO:=git
endef
define Prepare/znc-playback
$(eval $(Download/znc-playback))
xzcat $(DL_DIR)/$(FILE) | tar -C $(PKG_BUILD_DIR) $(TAR_OPTIONS)
$(LN) $(PKG_BUILD_DIR)/znc-mod-playback/playback.cpp $(PKG_BUILD_DIR)/modules/playback.cpp
endef
define push
define Package/znc-mod-push
$(Package/znc/default)
TITLE+= (push plugin)
DEPENDS:=znc
endef
define Package/znc-mod-push/description
Send push notification to connected and configured devices. Refer to project Documentation
on how to setup.
endef
define Package/znc-mod-push/install
$(INSTALL_DIR) $$(1)/usr/lib/znc/
$(INSTALL_BIN) $$(PKG_INSTALL_DIR)/usr/lib/znc/push.so $$(1)/usr/lib/znc/
endef
ZNC_MODULES += znc-mod-push
$(if $(CONFIG_PACKAGE_znc-mod-push),ZNC_MODULE_TARGETS += push.so)
endef
define Download/znc-push
VERSION:=23d84678de2696e0b1f51aa5074764d29a98d37b
SUBDIR:=znc-mod-push
FILE:=znc-push-$$(VERSION).tar.xz
URL:=https://github.com/amyreese/znc-push.git
MIRROR_HASH:=b1ec076ee8a37b8ff8cb530852d7639fbfce3df4a963cae29375056382020394
PROTO:=git
endef
define Prepare/znc-push
$(eval $(Download/znc-push))
xzcat $(DL_DIR)/$(FILE) | tar -C $(PKG_BUILD_DIR) $(TAR_OPTIONS)
$(LN) $(PKG_BUILD_DIR)/znc-mod-push/push.cpp $(PKG_BUILD_DIR)/modules/push.cpp
endef
, := , , := ,
$(eval $(call module,adminlog,Log user connects and disconnects and failed \ $(eval $(call module,adminlog,Log user connects and disconnects and failed \
@ -233,9 +304,6 @@ $(eval $(call module,notify-connect,Sends a notice to all admins when a user \
$(eval $(call module,perform,Performs commands on connect.)) $(eval $(call module,perform,Performs commands on connect.))
$(eval $(call module,playback,Avoid repetitive playback buffers on re-connect \
with supported clients (e.g. mutter, colluquy)))
$(eval $(call module,raw,View all of the raw traffic.)) $(eval $(call module,raw,View all of the raw traffic.))
$(eval $(call module,route-replies,Routes back answers to the right client \ $(eval $(call module,route-replies,Routes back answers to the right client \
@ -263,6 +331,9 @@ $(eval $(call module,stickychan,Keeps you sticked to specific channels.))
$(eval $(call module,watch,Monitor activity for specific text patterns from \ $(eval $(call module,watch,Monitor activity for specific text patterns from \
specific users and have the text sent to a special query window.)) specific users and have the text sent to a special query window.))
$(eval $(call playback))
$(eval $(call push))
$(eval $(call webadmin)) $(eval $(call webadmin))
$(eval $(call webskin,dark-clouds)) $(eval $(call webskin,dark-clouds))
@ -286,5 +357,19 @@ CMAKE_OPTIONS += \
-DWANT_TCL=OFF \ -DWANT_TCL=OFF \
-DWANT_ZLIB=ON -DWANT_ZLIB=ON
define Build/Prepare
$(call Build/Prepare/Default)
ifneq ($(CONFIG_PACKAGE_znc-mod-playback),)
$(eval $(call Download,znc-playback))
$(Prepare/znc-playback)
endif
ifneq ($(CONFIG_PACKAGE_znc-mod-push),)
$(eval $(call Download,znc-push))
$(Prepare/znc-push)
endif
endef
$(eval $(call BuildPackage,znc)) $(eval $(call BuildPackage,znc))
$(foreach m,$(ZNC_MODULES),$(eval $(call BuildPackage,$(m)))) $(foreach m,$(ZNC_MODULES),$(eval $(call BuildPackage,$(m))))

View file

@ -1,291 +0,0 @@
--- /dev/null
+++ b/modules/playback.cpp
@@ -0,0 +1,288 @@
+/*
+ * Copyright (C) 2015 J-P Nurmi
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#include <znc/Modules.h>
+#include <znc/IRCNetwork.h>
+#include <znc/Client.h>
+#include <znc/Buffer.h>
+#include <znc/Utils.h>
+#include <znc/Query.h>
+#include <znc/Chan.h>
+#include <znc/znc.h>
+#include <znc/version.h>
+#include <sys/time.h>
+#include <cfloat>
+
+#if (VERSION_MAJOR < 1) || (VERSION_MAJOR == 1 && VERSION_MINOR < 6)
+#error The playback module requires ZNC version 1.6.0 or later.
+#endif
+
+static const char* PlaybackCap = "znc.in/playback";
+
+class CPlaybackMod : public CModule
+{
+public:
+ MODCONSTRUCTOR(CPlaybackMod)
+ {
+ m_play = false;
+ AddHelpCommand();
+ AddCommand("Clear", static_cast<CModCommand::ModCmdFunc>(&CPlaybackMod::ClearCommand), "<buffer(s)>", "Clears playback for given buffers.");
+ AddCommand("Play", static_cast<CModCommand::ModCmdFunc>(&CPlaybackMod::PlayCommand), "<buffer(s)> [from] [to]", "Sends playback for given buffers.");
+ AddCommand("List", static_cast<CModCommand::ModCmdFunc>(&CPlaybackMod::ListCommand), "[buffer(s)]", "Lists available/matching buffers.");
+ AddCommand("Limit", static_cast<CModCommand::ModCmdFunc>(&CPlaybackMod::LimitCommand), "<client> [limit]", "Get/set the buffer limit (<= 0 to clear) for the given client.");
+ }
+
+ void OnClientCapLs(CClient* client, SCString& caps) override
+ {
+ caps.insert(PlaybackCap);
+ }
+
+ bool IsClientCapSupported(CClient* client, const CString& cap, bool state) override
+ {
+ return cap.Equals(PlaybackCap);
+ }
+
+ EModRet OnChanBufferStarting(CChan& chan, CClient& client) override
+ {
+ if (!m_play && client.IsCapEnabled(PlaybackCap))
+ return HALTCORE;
+ return CONTINUE;
+ }
+
+ EModRet OnChanBufferPlayLine(CChan& chan, CClient& client, CString& line) override
+ {
+ if (!m_play && client.IsCapEnabled(PlaybackCap))
+ return HALTCORE;
+ return CONTINUE;
+ }
+
+ EModRet OnChanBufferEnding(CChan& chan, CClient& client) override
+ {
+ if (!m_play && client.IsCapEnabled(PlaybackCap))
+ return HALTCORE;
+ return CONTINUE;
+ }
+
+ EModRet OnPrivBufferPlayLine(CClient& client, CString& line) override
+ {
+ if (!m_play && client.IsCapEnabled(PlaybackCap))
+ return HALTCORE;
+ return CONTINUE;
+ }
+
+ void ClearCommand(const CString& line)
+ {
+ // CLEAR <buffer(s)>
+ const CString arg = line.Token(1);
+ if (arg.empty() || !line.Token(2).empty())
+ return;
+ std::vector<CChan*> chans = FindChans(arg);
+ for (CChan* chan : chans)
+ chan->ClearBuffer();
+ std::vector<CQuery*> queries = FindQueries(arg);
+ for (CQuery* query : queries)
+ query->ClearBuffer();
+ }
+
+ void PlayCommand(const CString& line)
+ {
+ // PLAY <buffer(s)> [from] [to]
+ const CString arg = line.Token(1);
+ if (arg.empty() || !line.Token(4).empty())
+ return;
+ double from = line.Token(2).ToDouble();
+ double to = DBL_MAX;
+ if (!line.Token(3).empty())
+ to = line.Token(3).ToDouble();
+ int limit = -1;
+ if (CClient* client = GetClient())
+ limit = GetLimit(client->GetIdentifier());
+ std::vector<CChan*> chans = FindChans(arg);
+ for (CChan* chan : chans) {
+ if (chan->IsOn() && !chan->IsDetached()) {
+ CBuffer lines = GetLines(chan->GetBuffer(), from, to, limit);
+ m_play = true;
+ chan->SendBuffer(GetClient(), lines);
+ m_play = false;
+ }
+ }
+ std::vector<CQuery*> queries = FindQueries(arg);
+ for (CQuery* query : queries) {
+ CBuffer lines = GetLines(query->GetBuffer(), from, to, limit);
+ m_play = true;
+ query->SendBuffer(GetClient(), lines);
+ m_play = false;
+ }
+ }
+
+ void ListCommand(const CString& line)
+ {
+ // LIST [buffer(s)]
+ CString arg = line.Token(1);
+ if (arg.empty())
+ arg = "*";
+ std::vector<CChan*> chans = FindChans(arg);
+ for (CChan* chan : chans) {
+ if (chan->IsOn() && !chan->IsDetached()) {
+ CBuffer buffer = chan->GetBuffer();
+ if (!buffer.IsEmpty()) {
+ timeval from = UniversalTime(buffer.GetBufLine(0).GetTime());
+ timeval to = UniversalTime(buffer.GetBufLine(buffer.Size() - 1).GetTime());
+ PutModule(chan->GetName() + " " + CString(Timestamp(from)) + " " + CString(Timestamp(to)));
+ }
+ }
+ }
+ std::vector<CQuery*> queries = FindQueries(arg);
+ for (CQuery* query : queries) {
+ CBuffer buffer = query->GetBuffer();
+ if (!buffer.IsEmpty()) {
+ timeval from = UniversalTime(buffer.GetBufLine(0).GetTime());
+ timeval to = UniversalTime(buffer.GetBufLine(buffer.Size() - 1).GetTime());
+ PutModule(query->GetName() + " " + CString(Timestamp(from)) + " " + CString(Timestamp(to)));
+ }
+ }
+ }
+
+ void LimitCommand(const CString& line)
+ {
+ // LIMIT <client> [limit]
+ const CString client = line.Token(1);
+ if (client.empty()) {
+ PutModule("Usage: LIMIT <client> [limit]");
+ return;
+ }
+ const CString arg = line.Token(2);
+ int limit = GetLimit(client);
+ if (!arg.empty()) {
+ limit = arg.ToInt();
+ SetLimit(client, limit);
+ }
+ if (limit <= 0)
+ PutModule(client + " buffer limit: -");
+ else
+ PutModule(client + " buffer limit: " + CString(limit));
+ }
+
+ EModRet OnSendToClient(CString& line, CClient& client) override
+ {
+ if (client.IsAttached() && client.IsCapEnabled(PlaybackCap) && !line.Token(0).Equals("CAP")) {
+ MCString tags = CUtils::GetMessageTags(line);
+ if (tags.find("time") == tags.end()) {
+ // CUtils::FormatServerTime() converts to UTC
+ tags["time"] = CUtils::FormatServerTime(LocalTime());
+ CUtils::SetMessageTags(line, tags);
+ }
+ }
+ return CONTINUE;
+ }
+
+private:
+ static double Timestamp(timeval tv)
+ {
+ return tv.tv_sec + tv.tv_usec / 1000000.0;
+ }
+
+ static timeval LocalTime()
+ {
+ timeval tv;
+ if (gettimeofday(&tv, NULL) == -1) {
+ tv.tv_sec = time(NULL);
+ tv.tv_usec = 0;
+ }
+ return tv;
+ }
+
+ static timeval UniversalTime(timeval tv = LocalTime())
+ {
+ tm stm;
+ memset(&stm, 0, sizeof(stm));
+ const time_t secs = tv.tv_sec; // OpenBSD has tv_sec as int, so explicitly convert it to time_t to make gmtime_r() happy
+ gmtime_r(&secs, &stm);
+ const char* tz = getenv("TZ");
+ setenv("TZ", "UTC", 1);
+ tzset();
+ tv.tv_sec = mktime(&stm);
+ if (tz)
+ setenv("TZ", tz, 1);
+ else
+ unsetenv("TZ");
+ tzset();
+ return tv;
+ }
+
+ std::vector<CChan*> FindChans(const CString& arg) const
+ {
+ std::vector<CChan*> chans;
+ CIRCNetwork* network = GetNetwork();
+ if (network) {
+ VCString vargs;
+ arg.Split(",", vargs, false);
+
+ for (const CString& name : vargs) {
+ std::vector<CChan*> found = network->FindChans(name);
+ chans.insert(chans.end(), found.begin(), found.end());
+ }
+ }
+ return chans;
+ }
+
+ std::vector<CQuery*> FindQueries(const CString& arg) const
+ {
+ std::vector<CQuery*> queries;
+ CIRCNetwork* network = GetNetwork();
+ if (network) {
+ VCString vargs;
+ arg.Split(",", vargs, false);
+
+ for (const CString& name : vargs) {
+ std::vector<CQuery*> found = network->FindQueries(name);
+ queries.insert(queries.end(), found.begin(), found.end());
+ }
+ }
+ return queries;
+ }
+
+ int GetLimit(const CString& client) const
+ {
+ return GetNV(client).ToInt();
+ }
+
+ void SetLimit(const CString& client, int limit)
+ {
+ if (limit > 0)
+ SetNV(client, CString(limit));
+ else
+ DelNV(client);
+ }
+
+ static CBuffer GetLines(const CBuffer& buffer, double from, double to, int limit)
+ {
+ CBuffer lines(buffer.Size());
+ for (size_t i = 0; i < buffer.Size(); ++i) {
+ const CBufLine& line = buffer.GetBufLine(i);
+ timeval tv = UniversalTime(line.GetTime());
+ if (from < Timestamp(tv) && to >= Timestamp(tv))
+ lines.AddLine(line.GetFormat(), line.GetText(), &tv);
+ }
+ if (limit > 0)
+ lines.SetLineCount(limit);
+ return lines;
+ }
+
+ bool m_play;
+};
+
+GLOBALMODULEDEFS(CPlaybackMod, "An advanced playback module for ZNC")

View file

@ -1,12 +1,12 @@
include $(TOPDIR)/rules.mk include $(TOPDIR)/rules.mk
PKG_NAME:=apk PKG_NAME:=apk
PKG_VERSION:=2.12.4 PKG_VERSION:=2.12.11
PKG_RELEASE:=$(AUTORELEASE) PKG_RELEASE:=1
PKG_SOURCE:=apk-tools-v$(PKG_VERSION).tar.gz PKG_SOURCE:=apk-tools-v$(PKG_VERSION).tar.gz
PKG_SOURCE_URL:=https://gitlab.alpinelinux.org/alpine/apk-tools/-/archive/v$(PKG_VERSION) PKG_SOURCE_URL:=https://gitlab.alpinelinux.org/alpine/apk-tools/-/archive/v$(PKG_VERSION)
PKG_HASH:=41110665f7d14ef9678c389687aab0fa6c0a6be19e1a3dabbab6b20b17f3bacc PKG_HASH:=2cc2cd8dd515a729609066f08edc7317b5bca33a335ca4f6a56367aa018856c5
PKG_BUILD_DIR:=$(BUILD_DIR)/apk-tools-v$(PKG_VERSION) PKG_BUILD_DIR:=$(BUILD_DIR)/apk-tools-v$(PKG_VERSION)
PKG_MAINTAINER:=Paul Spooren <mail@aparcar.org> PKG_MAINTAINER:=Paul Spooren <mail@aparcar.org>

View file

@ -16,7 +16,7 @@ Signed-off-by: Rosen Penev <rosenp@gmail.com>
--- a/libfetch/common.c --- a/libfetch/common.c
+++ b/libfetch/common.c +++ b/libfetch/common.c
@@ -499,15 +499,11 @@ static int fetch_ssl_setup_client_certif @@ -531,15 +531,11 @@ static int fetch_ssl_setup_client_certif
int int
fetch_ssl(conn_t *conn, const struct url *URL, int verbose) fetch_ssl(conn_t *conn, const struct url *URL, int verbose)
{ {
@ -50,7 +50,7 @@ Signed-off-by: Rosen Penev <rosenp@gmail.com>
#include <fetch.h> #include <fetch.h>
#include "apk_defines.h" #include "apk_defines.h"
@@ -385,25 +380,6 @@ static int parse_options(int argc, char @@ -378,25 +373,6 @@ static int parse_options(int argc, char
return 0; return 0;
} }
@ -76,7 +76,7 @@ Signed-off-by: Rosen Penev <rosenp@gmail.com>
static void on_sigwinch(int s) static void on_sigwinch(int s)
{ {
apk_reset_screen_width(); apk_reset_screen_width();
@@ -484,7 +460,7 @@ int main(int argc, char **argv) @@ -475,7 +451,7 @@ int main(int argc, char **argv)
apk_force |= applet->forced_force; apk_force |= applet->forced_force;
} }