1. added multipath protocol and schema suport

2. added SCTP protocol and schema support
3. added set of NAS models support (Asustor, ReadyNAS, Drobo, QNAP, WD, Synology, Terramaster)
4. moved to fc00::/7 private segment
5. added Windows, MacOS and Linux UI for peers edit and current status
This commit is contained in:
vadym 2022-10-27 22:03:37 +03:00
parent cfa293d189
commit d8a4000141
198 changed files with 8589 additions and 697 deletions

View file

@ -0,0 +1,7 @@
#!/bin/sh
CFG=/etc/default_config/uLinux.conf
echo vendor=QNAP
echo vendorOperatingSystemName=$(/sbin/getcfg System OS -f $CFG)
echo firmwareVersion=$(/sbin/getcfg System Version -f $CFG)
echo model=$(/sbin/getcfg System Model -f $CFG)
echo serial=$(/sbin/get_hwsn)

View file

@ -0,0 +1,31 @@
#!/bin/sh
#we want read:
#export HTTP_COOKIE='qnapuser=admin; qnappwd=L4edNyoCC15.kDBLIN05480'
IFS=';'
for x in $HTTP_COOKIE
do
eval $x
done
[ -z ${qnapuser} ] && exit 1
[ -z ${qnappwd} ] && exit 1
#exit with zero status on auth success
#2-pass auth
S=$(curl -s -k -L "http://127.0.0.1:58080/cgi-bin/authLogin.cgi?user=${qnapuser}&pwd=${qnappwd}" | tr -d '\040\011\012\015' | grep -F '<authPassed><![CDATA[1]]></authPassed>')
[ ! 0 -eq ${#S} ] && exit 0
AUTH_PORT=$(cat /etc/apache-sys-proxy.conf | grep Listen | awk '{print $2}')
if [ -n $AUTH_PORT ] ; then
AUTH_PORT=8080
fi
S=$(curl -s -k -L "http://127.0.0.1:${AUTH_PORT}/cgi-bin/authLogin.cgi?user=${qnapuser}&pwd=${qnappwd}" | tr -d '\040\011\012\015' | grep -F '<authPassed><![CDATA[1]]></authPassed>')
[ ! 0 -eq ${#S} ] && exit 0
#fallback to plain password auth
#decode password first
plain_pwd=$(openssl enc -base64 -d <<< ${qnappwd})
[ -z $plain_pwd ] && exit 1
S=$(curl -s -k -L "http://127.0.0.1:${AUTH_PORT}/cgi-bin/authLogin.cgi?user=${qnapuser}&plain_pwd=${plain_pwd}" | tr -d '\040\011\012\015' | grep -F '<authPassed><![CDATA[1]]></authPassed>')
[ 0 -eq ${#S} ] && exit 1 || exit 0

View file

@ -0,0 +1,12 @@
#!/bin/sh
log_exit(){
echo $2
exit $1
}
[ -z "$MESH_USER_NAME" ] && log_exit 1 "Credentials are not set. Remove aborted"
rm "$MESH_APP_ROOT/bin/mesh
rm -rf "$MESH_APP_ROOT/www"