Merge pull request #630 from micmac1/fs-1106
freeswitch: update to 1.10.6
This commit is contained in:
commit
cda90c0df7
14 changed files with 52 additions and 144 deletions
|
@ -8,13 +8,13 @@
|
|||
include $(TOPDIR)/rules.mk
|
||||
|
||||
PKG_NAME:=freeswitch
|
||||
PKG_VERSION:=1.10.5
|
||||
PKG_RELEASE:=6
|
||||
PKG_VERSION:=1.10.6
|
||||
PKG_RELEASE:=1
|
||||
PKG_MAINTAINER:=Sebastian Kemper <sebastian_ml@gmx.net>
|
||||
|
||||
PKG_SOURCE:=freeswitch-$(PKG_VERSION).-release.tar.xz
|
||||
PKG_SOURCE_URL:=https://files.freeswitch.org/releases/freeswitch
|
||||
PKG_HASH:=3e26600767a82946eca94af2c8f14712783aa83db5fb1cc57585f544aecce327
|
||||
PKG_HASH:=9a08d4e184e6d715e1c12c43a0f901597151752ef236f0a37e40996272b5c38d
|
||||
|
||||
PKG_CPE_ID:=cpe:/a:freeswitch:freeswitch
|
||||
|
||||
|
|
|
@ -4,6 +4,7 @@ config freeswitch 'general'
|
|||
option log_stderr '1'
|
||||
option log_stdout '1'
|
||||
option options '-nonat -np'
|
||||
#option term_timeout '10' # seconds to wait after sending TERM signal
|
||||
|
||||
config freeswitch 'directories'
|
||||
option cache '/tmp/freeswitch/cache'
|
||||
|
|
|
@ -4,8 +4,9 @@ NAME=freeswitch
|
|||
COMMAND=/etc/init.d/$NAME
|
||||
|
||||
LOGGER="/usr/bin/logger -t $NAME-hotplug"
|
||||
LOG_ERR="$LOGGER -p user.err --"
|
||||
LOG_NOTICE="$LOGGER -p user.notice --"
|
||||
LOG_ERR="$LOGGER -p daemon.err --"
|
||||
LOG_INFO="$LOGGER -p daemon.info --"
|
||||
LOG_WARN="$LOGGER -p daemon.warn --"
|
||||
|
||||
[ "$ACTION" = ifup ] || exit 0
|
||||
|
||||
|
@ -18,7 +19,7 @@ config_get interface hotplug interface
|
|||
|
||||
pidof $NAME &> /dev/null
|
||||
if [ $? -eq 0 ]; then
|
||||
$LOG_NOTICE stopping $NAME
|
||||
$LOG_INFO stopping $NAME
|
||||
$COMMAND stop &> /dev/null
|
||||
fi
|
||||
|
||||
|
@ -43,7 +44,7 @@ config_get mount_point hotplug mount_point
|
|||
|
||||
while [ -n "$notReady" -a $tmp_timeout -gt 0 ]; do
|
||||
if [ "$notReady" != start ]; then
|
||||
$LOG_NOTICE "$mnt" not yet mounted, timeout in $tmp_timeout s
|
||||
$LOG_INFO "$mnt" not yet mounted, timeout in $tmp_timeout s
|
||||
sleep 5
|
||||
tmp_timeout=$(($tmp_timeout-5))
|
||||
fi
|
||||
|
@ -61,7 +62,7 @@ config_get mount_point hotplug mount_point
|
|||
$LOG_ERR not starting $NAME
|
||||
exit 1
|
||||
else
|
||||
$LOG_NOTICE "$mnt" mounted
|
||||
$LOG_INFO "$mnt" mounted
|
||||
fi
|
||||
|
||||
}
|
||||
|
@ -87,7 +88,7 @@ config_get_bool ntpd hotplug ntpd 0
|
|||
|
||||
while [ -n "$notReady" -a $tmp_timeout -gt 0 ]; do
|
||||
if [ "$notReady" != start ]; then
|
||||
$LOG_NOTICE system time not in sync yet, timeout in $tmp_timeout s
|
||||
$LOG_INFO system time not in sync yet, timeout in $tmp_timeout s
|
||||
sleep 5
|
||||
tmp_timeout=$(($tmp_timeout-5))
|
||||
fi
|
||||
|
@ -97,20 +98,20 @@ config_get_bool ntpd hotplug ntpd 0
|
|||
result=$(ntpq -c 'timeout 300' -c 'rv 0 stratum' 2> /dev/null | \
|
||||
awk -F '=' '{print $2}' | grep -o -E '^[0-9]+')
|
||||
if [ -z $result ]; then
|
||||
$LOG_ERR failed to extract stratum from ntpd
|
||||
$LOG_WARN failed to extract stratum from ntpd
|
||||
notReady="unable to extract stratum"
|
||||
else
|
||||
$LOG_NOTICE ntpd stratum $result
|
||||
$LOG_INFO ntpd stratum $result
|
||||
if [ $result -lt 16 ] 2> /dev/null; then
|
||||
result=$(ntpq -c 'timeout 300' -c 'rv 0 offset' 2> /dev/null \
|
||||
| awk -F '=' '{print $2}' | grep -o -E '^-?[0-9]+')
|
||||
| awk -F '=' '{print $2}' | grep -o -E '^[-+]?[0-9]+')
|
||||
if [ -z $result ]; then
|
||||
$LOG_ERR failed to extract offset from ntpd
|
||||
$LOG_WARN failed to extract offset from ntpd
|
||||
notReady="unable to extract offset"
|
||||
else
|
||||
# "-0" looks stupid, so remove "-"
|
||||
result=$(echo $result | grep -o '[0-9]*')
|
||||
$LOG_NOTICE ntpd to system time offset \+\/\- $result ms
|
||||
$LOG_INFO ntpd to system time offset \+\/\- $result ms
|
||||
# If offset < 100 ms consider system time in sync
|
||||
[ $result -lt 100 ] || notReady="system time not in sync yet"
|
||||
fi
|
||||
|
@ -125,7 +126,7 @@ config_get_bool ntpd hotplug ntpd 0
|
|||
$LOG_ERR not starting $NAME
|
||||
exit 1
|
||||
else
|
||||
$LOG_NOTICE system time in sync
|
||||
$LOG_INFO system time in sync
|
||||
fi
|
||||
|
||||
}
|
||||
|
@ -134,7 +135,7 @@ $COMMAND start &> /dev/null
|
|||
sleep 1
|
||||
pidof $NAME &>/dev/null
|
||||
if [ $? -eq 0 ]; then
|
||||
$LOG_NOTICE started $NAME due to \"ifup "$INTERFACE"\" event
|
||||
$LOG_INFO started $NAME due to \"ifup "$INTERFACE"\" event
|
||||
else
|
||||
$LOG_ERR start of $NAME due to \"ifup "$INTERFACE"\" event failed
|
||||
exit 1
|
||||
|
|
|
@ -10,7 +10,10 @@ USE_PROCD=1
|
|||
NAME=freeswitch
|
||||
COMMAND=/usr/bin/$NAME
|
||||
|
||||
LOGGER="/usr/bin/logger -p user.err -s -t $NAME --"
|
||||
LOGGER="/usr/bin/logger -s -t $NAME"
|
||||
LOG_ERR="$LOGGER -p daemon.err --"
|
||||
LOG_WARN="$LOGGER -p daemon.warn --"
|
||||
LOG_INFO="$LOGGER -p daemon.info --"
|
||||
|
||||
start_service() {
|
||||
dir_etc=/etc/$NAME
|
||||
|
@ -21,7 +24,7 @@ start_service() {
|
|||
|
||||
config_get_bool enabled general enabled 0
|
||||
if [ $enabled -eq 0 ]; then
|
||||
$LOGGER service not enabled in /etc/config/$NAME
|
||||
$LOG_ERR service not enabled in /etc/config/$NAME
|
||||
exit 1
|
||||
fi
|
||||
|
||||
|
@ -37,6 +40,14 @@ start_service() {
|
|||
|
||||
config_get options general options
|
||||
|
||||
config_get term_timeout general term_timeout default
|
||||
if [ default = "$term_timeout" ]; then
|
||||
$LOG_INFO using procd\'s default term_timeout
|
||||
elif ! [ 0 -lt "$term_timeout" ] 2>/dev/null; then
|
||||
$LOG_ERR invalid term_timeout in /etc/config/$NAME
|
||||
exit 1
|
||||
fi
|
||||
|
||||
for i in "$dir_localstate" "$dir_run"; do
|
||||
if ! [ -e "$i" ]; then
|
||||
mkdir -m 0750 -p "$i"
|
||||
|
@ -47,8 +58,8 @@ start_service() {
|
|||
command -v su >/dev/null
|
||||
ret=$?
|
||||
if [ 0 != "$ret" ]; then
|
||||
$LOGGER utility \"su\" not available
|
||||
$LOGGER will not attempt to create directories
|
||||
$LOG_WARN utility \"su\" not available
|
||||
$LOG_WARN will not attempt to create directories
|
||||
else
|
||||
for i in "$dir_cache" \
|
||||
"$dir_db" \
|
||||
|
@ -84,5 +95,8 @@ start_service() {
|
|||
procd_set_param stderr $log_stderr
|
||||
# same for stdout
|
||||
procd_set_param stdout $log_stdout
|
||||
if ! [ default = "$term_timeout" ]; then
|
||||
procd_set_param term_timeout "$term_timeout"
|
||||
fi
|
||||
procd_close_instance
|
||||
}
|
||||
|
|
|
@ -1,11 +1,20 @@
|
|||
--- a/build/modmake.rulesam
|
||||
+++ b/build/modmake.rulesam
|
||||
@@ -2,7 +2,7 @@ AUTOMAKE_OPTIONS = foreign subdir-object
|
||||
@@ -1,8 +1,8 @@
|
||||
AUTOMAKE_OPTIONS = foreign subdir-objects
|
||||
AM_CFLAGS = $(SWITCH_AM_CFLAGS) $(SWITCH_ANSI_CFLAGS)
|
||||
AM_CPPFLAGS = $(SWITCH_AM_CXXFLAGS)
|
||||
-AM_CPPFLAGS = $(SWITCH_AM_CXXFLAGS)
|
||||
+AM_CPPFLAGS = $(SWITCH_AM_CPPFLAGS)
|
||||
AM_LDFLAGS = $(SWITCH_AM_LDFLAGS)
|
||||
-DEFAULT_VARS = CFLAGS="$(CFLAGS)" CPPFLAGS="$(CXXFLAGS)" LDFLAGS="$(LDFLAGS)" CC="$(CC)" CXX="$(CXX)"
|
||||
+DEFAULT_VARS = CFLAGS="$(CFLAGS)" CPPFLAGS="$(CPPFLAGS)" CXXFLAGS="$(CXXFLAGS)" LDFLAGS="$(LDFLAGS)" CC="$(CC)" CXX="$(CXX)"
|
||||
DEFAULT_ARGS = --build=$(build) --host=$(host) --target=$(target) --prefix="$(prefix)" --exec_prefix="$(exec_prefix)" --libdir="$(libdir)" --disable-shared --with-pic
|
||||
|
||||
moddir=@modulesdir@
|
||||
@@ -18,4 +18,4 @@ extraclean-modules: extraclean
|
||||
print_tests:
|
||||
@set +e; \
|
||||
test -z "$(TESTS)" || for i in $(TESTS); do echo $(subdir)/$$i; done;
|
||||
-
|
||||
\ No newline at end of file
|
||||
+
|
||||
|
|
|
@ -40,7 +40,7 @@
|
|||
AC_PATH_PROG([PKG_CONFIG], [pkg-config], [no])
|
||||
|
||||
case $host in
|
||||
@@ -1637,13 +1613,7 @@ AC_CHECK_PROG(PERL,perl,[ac_cv_have_perl
|
||||
@@ -1643,13 +1619,7 @@ AC_CHECK_PROG(PERL,perl,[ac_cv_have_perl
|
||||
# -a "x$ac_cv_have_EXTERN_h" != "xno"
|
||||
|
||||
if test "x$ac_cv_have_perl" != "xno"; then
|
||||
|
|
|
@ -1,49 +0,0 @@
|
|||
commit 70d1cbafe4ab0176cd9fc01f740e34cd1bae326b
|
||||
Author: Sebastian Kemper <sebastian_ml@gmx.net>
|
||||
Date: Wed Nov 13 20:29:50 2019 +0100
|
||||
|
||||
[gentls_cert] Update message digest
|
||||
|
||||
Debian Buster updated /etc/ssl/openssl.cnf to default to
|
||||
|
||||
MinProtocol = TLSv1.2
|
||||
CipherString = DEFAULT@SECLEVEL=2
|
||||
|
||||
gentls_cert currently uses SHA1 as message digest. According to OpenSSL
|
||||
documentation this only offers 80 bit of security. 80 bits is enough for
|
||||
security level 1, but not 2.
|
||||
|
||||
The OpenSSL default MD nowadays is SHA256. This commit updates
|
||||
gentls_cert to use it.
|
||||
|
||||
Issue was reported on the FS mailing list. The certificates created by
|
||||
gentls_cert caused "md too weak" errors and clients were unable to
|
||||
connect.
|
||||
|
||||
Signed-off-by: Sebastian Kemper <sebastian_ml@gmx.net>
|
||||
|
||||
--- a/scripts/gentls_cert.in
|
||||
+++ b/scripts/gentls_cert.in
|
||||
@@ -89,7 +89,7 @@ setup_ca() {
|
||||
|
||||
openssl req -out "${CONFDIR}/CA/cacert.pem" \
|
||||
-new -x509 -keyout "${CONFDIR}/CA/cakey.pem" \
|
||||
- -config "${TMPFILE}.cfg" -nodes -days ${DAYS} -sha1 >/dev/null || exit 1
|
||||
+ -config "${TMPFILE}.cfg" -nodes -days ${DAYS} -sha256 >/dev/null || exit 1
|
||||
cat "${CONFDIR}/CA/cacert.pem" > "${CONFDIR}/cafile.pem"
|
||||
cp $TMPFILE.cfg /tmp/ssl.cfg
|
||||
rm "${TMPFILE}.cfg"
|
||||
@@ -131,11 +131,11 @@ generate_cert() {
|
||||
|
||||
openssl req -new -out "${TMPFILE}.req" \
|
||||
-newkey rsa:${KEY_SIZE} -keyout "${TMPFILE}.key" \
|
||||
- -config "${TMPFILE}.cfg" -nodes -sha1 >/dev/null || exit 1
|
||||
+ -config "${TMPFILE}.cfg" -nodes -sha256 >/dev/null || exit 1
|
||||
|
||||
openssl x509 -req -CAkey "${CONFDIR}/CA/cakey.pem" -CA "${CONFDIR}/CA/cacert.pem" -CAcreateserial \
|
||||
-in "${TMPFILE}.req" -out "${TMPFILE}.crt" -extfile "${TMPFILE}.cfg" \
|
||||
- -extensions "${EXTENSIONS}" -days ${DAYS} -sha1 >/dev/null || exit 1
|
||||
+ -extensions "${EXTENSIONS}" -days ${DAYS} -sha256 >/dev/null || exit 1
|
||||
|
||||
cat "${TMPFILE}.crt" "${TMPFILE}.key" > "${CONFDIR}/${OUTFILE}"
|
||||
|
|
@ -12,7 +12,7 @@
|
|||
#include <errno.h>
|
||||
#include <string.h>
|
||||
#include <stdio.h>
|
||||
@@ -531,14 +532,10 @@ int main(void)
|
||||
@@ -534,14 +535,10 @@ int main(void)
|
||||
}], [
|
||||
ac_cv_strerror_r_rc_int=yes ], [
|
||||
ac_cv_strerror_r_rc_int=no ], [
|
||||
|
@ -42,7 +42,7 @@
|
|||
#include <errno.h>
|
||||
#include <string.h>
|
||||
#include <stdio.h>
|
||||
@@ -531,14 +532,10 @@ int main(void)
|
||||
@@ -534,14 +535,10 @@ int main(void)
|
||||
}], [
|
||||
ac_cv_strerror_r_rc_int=yes ], [
|
||||
ac_cv_strerror_r_rc_int=no ], [
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
--- a/configure.ac
|
||||
+++ b/configure.ac
|
||||
@@ -2069,7 +2069,12 @@ AC_SUBST(OUR_DISABLED_INSTALL_MODS)
|
||||
@@ -2075,7 +2075,12 @@ AC_SUBST(OUR_DISABLED_INSTALL_MODS)
|
||||
AC_SUBST(OUR_DISABLED_UNINSTALL_MODS)
|
||||
AC_SUBST(AM_MAKEFLAGS)
|
||||
|
||||
|
|
|
@ -1,10 +0,0 @@
|
|||
--- a/src/mod/applications/mod_spandsp/Makefile.am
|
||||
+++ b/src/mod/applications/mod_spandsp/Makefile.am
|
||||
@@ -4,6 +4,6 @@ MODNAME=mod_spandsp
|
||||
mod_LTLIBRARIES = mod_spandsp.la
|
||||
mod_spandsp_la_SOURCES = mod_spandsp.c udptl.c mod_spandsp_fax.c mod_spandsp_dsp.c mod_spandsp_codecs.c mod_spandsp_modem.c
|
||||
mod_spandsp_la_CFLAGS = $(AM_CFLAGS)
|
||||
-mod_spandsp_la_CPPFLAGS = $(SPANDSL_CFLAGS) -I.
|
||||
+mod_spandsp_la_CPPFLAGS = $(SPANDSP_CFLAGS) -I.
|
||||
mod_spandsp_la_LIBADD = $(switch_builddir)/libfreeswitch.la $(SPANDSP_LIBS) -ljpeg -lz -ltiff
|
||||
mod_spandsp_la_LDFLAGS = -avoid-version -module -no-undefined -shared
|
|
@ -1,24 +0,0 @@
|
|||
--- a/src/mod/endpoints/mod_gsmopen/Makefile.am
|
||||
+++ b/src/mod/endpoints/mod_gsmopen/Makefile.am
|
||||
@@ -1,19 +1,9 @@
|
||||
include $(top_srcdir)/build/modmake.rulesam
|
||||
MODNAME=mod_gsmopen
|
||||
|
||||
-SPANDSP_DIR=$(switch_srcdir)/libs/spandsp
|
||||
-SPANDSP_BUILDDIR=$(switch_builddir)/libs/spandsp
|
||||
-SPANDSP_LA=$(SPANDSP_BUILDDIR)/src/libspandsp.la
|
||||
-
|
||||
mod_LTLIBRARIES = mod_gsmopen.la
|
||||
mod_gsmopen_la_SOURCES = mod_gsmopen.cpp gsmopen_protocol.cpp
|
||||
mod_gsmopen_la_CXXFLAGS = $(SWITCH_AM_CXXFLAGS)
|
||||
-mod_gsmopen_la_CPPFLAGS = -I$(SPANDSP_DIR)/src -I$(SPANDSP_BUILDDIR)/src -I.
|
||||
-mod_gsmopen_la_LIBADD = $(switch_builddir)/libfreeswitch.la $(SPANDSP_LA)
|
||||
+mod_gsmopen_la_CPPFLAGS = $(SPANDSP_CFLAGS) -I.
|
||||
+mod_gsmopen_la_LIBADD = $(switch_builddir)/libfreeswitch.la $(SPANDSP_LIBS)
|
||||
mod_gsmopen_la_LDFLAGS = -avoid-version -module -no-undefined -lctb-0.16 -lgsmme
|
||||
-
|
||||
-BUILT_SOURCES = $(SPANDSP_LA)
|
||||
-
|
||||
-$(SPANDSP_LA): $(SPANDSP_DIR) $(SPANDSP_DIR)/.update
|
||||
- cd $(SPANDSP_BUILDDIR) && $(MAKE) CPPFLAGS="$(CPPFLAGS)" CFLAGS="$(CFLAGS)"
|
||||
- $(TOUCH_TARGET)
|
|
@ -1,6 +1,6 @@
|
|||
--- a/configure.ac
|
||||
+++ b/configure.ac
|
||||
@@ -703,7 +703,7 @@ PKG_CHECK_MODULES([MARIADB], [libmariadb
|
||||
@@ -709,7 +709,7 @@ PKG_CHECK_MODULES([MARIADB], [libmariadb
|
||||
])
|
||||
])
|
||||
|
||||
|
|
|
@ -1,18 +0,0 @@
|
|||
commit 9c01bd4c78c678e989ac77522145d3bd46352f6f
|
||||
Author: Ciprian <ciprian.dosoftei@gmail.com>
|
||||
Date: Tue Sep 1 12:13:28 2020 -0400
|
||||
|
||||
[mod_rayo] Enable -fno-common compilation
|
||||
|
||||
--- a/src/mod/event_handlers/mod_rayo/iks_helpers.h
|
||||
+++ b/src/mod/event_handlers/mod_rayo/iks_helpers.h
|
||||
@@ -51,8 +51,7 @@ struct xmpp_error {
|
||||
|
||||
#undef XMPP_ERROR
|
||||
#define XMPP_ERROR(def_name, name, type) \
|
||||
- SWITCH_DECLARE(const struct xmpp_error) def_name##_val; \
|
||||
- SWITCH_DECLARE(const struct xmpp_error *) def_name;
|
||||
+ extern const struct xmpp_error *def_name;
|
||||
#include "xmpp_errors.def"
|
||||
|
||||
/* See RFC-3920 XMPP core for error definitions */
|
|
@ -1,16 +0,0 @@
|
|||
--- a/src/include/switch_platform.h
|
||||
+++ b/src/include/switch_platform.h
|
||||
@@ -270,9 +270,13 @@ typedef intptr_t switch_ssize_t;
|
||||
#if defined(__FreeBSD__) && SIZEOF_VOIDP == 4
|
||||
#define TIME_T_FMT "d"
|
||||
#else
|
||||
+#if __USE_TIME_BITS64
|
||||
+#define TIME_T_FMT SWITCH_INT64_T_FMT
|
||||
+#else
|
||||
#define TIME_T_FMT "ld"
|
||||
#endif
|
||||
#endif
|
||||
+#endif
|
||||
|
||||
|
||||
#if UINTPTR_MAX == 0xffffffffffffffff
|
Loading…
Reference in a new issue