mirror of
https://github.com/crystalidea/qt6windows7.git
synced 2025-07-05 00:35:27 +08:00
qt 6.5.1 original
This commit is contained in:
36
tests/testserver/danted/danted.sh
Normal file
36
tests/testserver/danted/danted.sh
Normal file
@ -0,0 +1,36 @@
|
||||
#!/usr/bin/env bash
|
||||
# Copyright (C) 2018 The Qt Company Ltd.
|
||||
# SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only
|
||||
|
||||
set -ex
|
||||
|
||||
# package dante-server
|
||||
|
||||
# add users
|
||||
useradd -d /dev/null -s /bin/false qsockstest; echo "qsockstest:$PASS" | chpasswd
|
||||
|
||||
# install configurations and test data
|
||||
cp $TESTDATA/danted{,-authenticating}.conf /etc/
|
||||
|
||||
# Use the input environment variables to overwrite the default value of internal interfaces.
|
||||
if [ "$danted_internal" -a "$danted_internal" != eth0 ]
|
||||
then sed -i "s,internal: eth0 port = 1080,internal: $danted_internal port = 1080," /etc/danted.conf
|
||||
fi
|
||||
|
||||
if [ "$danted_auth_internal" -a "$danted_auth_internal" != eth0 ]
|
||||
then sed -i "s,internal: eth0 port = 1081,internal: $danted_auth_internal port = 1081," \
|
||||
/etc/danted-authenticating.conf
|
||||
fi
|
||||
|
||||
# Use the input environment variables to overwrite the default value of external interfaces.
|
||||
if [ "$danted_external" -a "$danted_external" != eth0 ]
|
||||
then sed -i "s,external: eth0,external: $danted_external," /etc/danted.conf
|
||||
fi
|
||||
|
||||
if [ "$danted_auth_external" -a "$danted_auth_external" != eth0 ]
|
||||
then sed -i "s,external: eth0,external: $danted_auth_external," /etc/danted-authenticating.conf
|
||||
fi
|
||||
|
||||
# enable service with installed configurations
|
||||
service danted start
|
||||
service danted-authenticating start
|
19
tests/testserver/danted/testdata/danted-authenticating.conf
vendored
Normal file
19
tests/testserver/danted/testdata/danted-authenticating.conf
vendored
Normal file
@ -0,0 +1,19 @@
|
||||
# A sample danted-authenticating.conf
|
||||
# See: https://www.inet.no/dante/doc/1.4.x/config/
|
||||
logoutput: /var/log/sockd-authenticating.log
|
||||
internal: eth0 port = 1081
|
||||
external: eth0
|
||||
method: username
|
||||
user.privileged: root
|
||||
user.notprivileged: nobody
|
||||
user.libwrap: nobody
|
||||
|
||||
client pass {
|
||||
from: 0.0.0.0/0 to: 0.0.0.0/0
|
||||
log: error connect disconnect
|
||||
}
|
||||
|
||||
pass {
|
||||
from: 0.0.0.0/0 to: 0.0.0.0/0
|
||||
log: error connect disconnect
|
||||
}
|
19
tests/testserver/danted/testdata/danted.conf
vendored
Normal file
19
tests/testserver/danted/testdata/danted.conf
vendored
Normal file
@ -0,0 +1,19 @@
|
||||
# A sample danted.conf
|
||||
# See: https://www.inet.no/dante/doc/1.4.x/config/
|
||||
logoutput: /var/log/sockd.log
|
||||
internal: eth0 port = 1080
|
||||
external: eth0
|
||||
method: username none
|
||||
user.privileged: proxy
|
||||
user.notprivileged: nobody
|
||||
user.libwrap: nobody
|
||||
|
||||
client pass {
|
||||
from: 0.0.0.0/0 to: 0.0.0.0/0
|
||||
log: error connect disconnect
|
||||
}
|
||||
|
||||
pass {
|
||||
from: 0.0.0.0/0 to: 0.0.0.0/0
|
||||
log: error connect disconnect
|
||||
}
|
Reference in New Issue
Block a user