Git Product home page Git Product logo

fritzbox7490_backup's Issues

Does not work for FritzOS 7.50

Hi,
i tried a lot of different backup scripts for FritzOs 7.50 and nothings works. the curl result just is always empty. Rebooting the router and updating phonebooks by bash script works fine.

If you have an idea how to upate to latest, please let me know. i checked the form input argument names and values and they did not change. messed around 2 hours for that, giving up at the moment :-(

my script, reduced to the needs:

#!/bin/bash
URL=https://192.168.188.1
USER=theuser
PASSWD=pwd
EXPORT_PW=pwd2
CURLUSERPASSSTRING="--user ${USER}:${PASSWD}"
CHALLENGE=`curl -s -k ${CURLUSERPASSSTRING} "${URL}/login_sid.lua" | grep Challenge | sed -e 's/.*<Challenge>//' | sed -e 's/<\/Challenge>.*//'`
DATE=`date +"%d.%m.%Y %H:%M:%S"`
if [ -z "${CHALLENGE}" ] ; then
	echo "Error getting challenge using ${URL}" >&2
else
    MD5=$(echo -n ${CHALLENGE}"-"${PASSWD} | perl -p -e 'use Encode qw/encode/; print encode("UTF-16LE","$_"); $_="";' | md5sum -b | awk '{print substr($0,1,32)}')
	RESPONSE=${CHALLENGE}"-"${MD5}
    SID=`curl -s -i -k ${CURLUSERPASSSTRING} -d 'response='${RESPONSE} -d 'page=' -d 'username='${USER} ${URL}/login_sid.lua | grep SID | sed -e 's/.*<SID>//' | sed -e 's/<\/SID>.*//'`
	curl -k ${CURLUSERPASSSTRING} --form "sid=${SID}" --form "ImportExportPassword=${EXPORT_PW}" --form "ConfigExport=" ${URL}/cgi-bin/firmwarecfg
fi

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.