Allow2010 Posted March 27, 2012 Share Posted March 27, 2012 (edited) _FB_ToolsThe German company AVM (http://en.avm.de/) sells a router with many extra functions. This router is called FritzBox and comes in different models.Some models have more features than others, but all have a web-interface to control the features. _FB_Tools allows to control this web-interface by reading settings from the generated webpages and settings functions based on those settings. But as the web-interface changes from model to model and from firmware version to firmware version _FB_Tools needs to be constantly modified to work with the latest firmware.Currently I only use the FritzBox model 7490 http://en.avm.de/products/fritzbox/fritzbox-7490/ and i only test with this model. Other models may or may not work out of the box, but if a functions does not work, it is in most cases easy to modify the code to read and send commands for your model. _FB_Tools can help with home automation tasks, like switching WLAN, GuestWLAN, or GuestLAN functions, or DECT (wireless phones) functions.You can also dial numbers or work with phone-books, change settings of an answering machine or upload audio files to it.The ZIP also includes a simple test and demo tool. _FB_Tools_old.zip _FB_Tools_1.636-31656.zip Edited October 24, 2015 by Allow2010 nobbitry 1 Link to comment Share on other sites More sharing options...
UEZ Posted March 27, 2012 Share Posted March 27, 2012 Probably only users from Germany and around will know the Fritz.Box made by AVM.Br,UEZ Please don't send me any personal message and ask for support! I will not reply! Selection of finest graphical examples at Codepen.io The own fart smells best! ✌Her 'sikim hıyar' diyene bir avuç tuz alıp koşma!¯\_(ツ)_/¯ ٩(●̮̮̃•̃)۶ ٩(-̮̮̃-̃)۶ૐ Link to comment Share on other sites More sharing options...
Allow2010 Posted November 18, 2012 Author Share Posted November 18, 2012 i am still wondering: almost 230 downloads and still no reply...is it tooo easy or too complicated? Anyone interested in an update? Link to comment Share on other sites More sharing options...
Allow2010 Posted December 15, 2012 Author Share Posted December 15, 2012 added version 1.2 with support for new fritzOS 5.50 (yet untested as i do not yet have a box running in 5.50) Link to comment Share on other sites More sharing options...
KaFu Posted December 16, 2012 Share Posted December 16, 2012 Downloaded and bookmarked , will definitely give it a try! OS: Win10-22H2 - 64bit - German, AutoIt Version: 3.3.16.1, AutoIt Editor: SciTE, Website: https://funk.eu AMT - Auto-Movie-Thumbnailer (2024-Oct-13) BIC - Batch-Image-Cropper (2023-Apr-01) COP - Color Picker (2009-May-21) DCS - Dynamic Cursor Selector (2024-Oct-13) HMW - Hide my Windows (2024-Oct-19) HRC - HotKey Resolution Changer (2012-May-16) ICU - Icon Configuration Utility (2018-Sep-16) SMF - Search my Files (2024-Oct-20) - THE file info and duplicates search tool SSD - Set Sound Device (2017-Sep-16) Link to comment Share on other sites More sharing options...
LeMayne Posted January 8, 2013 Share Posted January 8, 2013 @Allow2010 Thank you, great work. Downloaded it, made a litte change to the example script (toggle answering machine on / off). But there is an error: nowriteaccess What can I do? (Fritz!Box 7390, FRITZ!OS 05.50, IP 192.168.1.1) LeMayne _FB_Tools.ini: [box] password = "xxx" use_lua_login=2 localfritzbox_ip_or_name = "192.168.1.1" Logfile: 08.01.2013-10:55:49: Init OK 08.01.2013-10:55:49: This is a LUA page: /login_sid.lua?sid=0000000000000000 08.01.2013-10:55:49: 1 fields found, adding query to request 08.01.2013-10:55:49: Query was built: sid=0000000000000000 08.01.2013-10:55:49: Challenge found: 1492a178 08.01.2013-10:55:49: Response calculated: 1492a178-9fd18e0619cefc6e580bf1ef2a4acf39 08.01.2013-10:55:49: This is a LUA page: /login_sid.lua?sid=0000000000000000 08.01.2013-10:55:49: 2 fields found, adding query to request 08.01.2013-10:55:49: Query was built: login:command/response=1492a178-9fd18e0619cefc6e580bf1ef2a4acf39&response=1492a178-9fd18e0619cefc6e580bf1ef2a4acf39 08.01.2013-10:55:50: Error: Login failed - no writeaccess 08.01.2013-10:55:50: Login with LUA page failed - now we try HTML login 08.01.2013-10:55:50: This is a FORM page: /cgi-bin/webcm 08.01.2013-10:55:50: 2 fields found, adding query to request 08.01.2013-10:55:50: Query was built: getpage=../html/login_sid.xml&sid=0000000000000000 08.01.2013-10:55:50: Error: SessionInfo was not found 08.01.2013-10:55:50: Challenge found: Challenge 08.01.2013-10:55:50: Response calculated: Challenge-489325baa2ab726b8274472007be3159 08.01.2013-10:55:50: This is a FORM page: /cgi-bin/webcm 08.01.2013-10:55:50: 3 fields found, adding query to request 08.01.2013-10:55:50: Query was built: getpage=../html/login_sid.xml&login:command/response=Challenge-489325baa2ab726b8274472007be3159&response=Challenge-489325baa2ab726b8274472007be3159 08.01.2013-10:55:50: Error: SessionInfo was not found 08.01.2013-10:55:50: Error: Login failed - no writeaccess 08.01.2013-10:55:50: Login failed Link to comment Share on other sites More sharing options...
Allow2010 Posted January 22, 2013 Author Share Posted January 22, 2013 sorry, as mentioned it is untested with current Firmware...as soon as i can find the time i will try to get a FB with latest FW Link to comment Share on other sites More sharing options...
Allow2010 Posted May 12, 2013 Author Share Posted May 12, 2013 (edited) Version 1.3 - fixed new login functions for Fritz OS 5.50 and above - synced with changes in the php version - seperated post and get functions to be more like the php version (easier to maintain) - modified a lot of functions to work with older and newer FritzOS versions - split in two includes, one for the basics (valid for all devices) and on for specific funktions - updated to new winhttp udf 1.6.2.8 - a lot of small changes and corrections - Important: the API works fine with FritzOS 5.50 and older versions (5.20, 5.22, end even older version without LUA login), but not all tools are updates to work with 5.50 Edited May 12, 2013 by Allow2010 Link to comment Share on other sites More sharing options...
Allow2010 Posted May 12, 2013 Author Share Posted May 12, 2013 (edited) just tested and it also works fine with lates labor FRITZ!OS 05.55-25188 BETA Edited May 12, 2013 by Allow2010 Link to comment Share on other sites More sharing options...
Allow2010 Posted May 14, 2013 Author Share Posted May 14, 2013 Version 1.4 added in future i will only support latest version of FritzOS and all functions for old versions will be removed. If you need to control a Box with old FritzOS, you need to use older _FB_Tools version, or you need to edit current version to fit your needs. Note: Diversity functions does not yet work with latest FritzOS Link to comment Share on other sites More sharing options...
Allow2010 Posted May 15, 2013 Author Share Posted May 15, 2013 (edited) removed Edited May 17, 2013 by Allow2010 Link to comment Share on other sites More sharing options...
Allow2010 Posted May 17, 2013 Author Share Posted May 17, 2013 1.5 17.05.2013 - code cleanup - bugfixes - https now works with Windows 8 - you can now use the https certificate of your fritzbox to make communication over the Internet more secure - new function _FB_SetBoxname - new function _FB_UnBlacklist - enhanced _FB_Blacklist - _FB_SetDiversity still not working with lates FOS 5.50 (easy, just time consuming) - new function _FB_BoxReady Link to comment Share on other sites More sharing options...
CFIHS Posted August 13, 2013 Share Posted August 13, 2013 (edited) Func _FB_IsLUA () $aSS = StringSplit(_WinHttpSimpleRequest($hConnect, "GET", "/cgi-bin/system_status"), "-") $sFirmwareversion = StringTrimLeft($aSS[8], 2) If $sFirmwareversion > 0522 Then Return 1 Else Return 0 EndIf EndFunc ;==>_FB_IsLUA Edited August 14, 2013 by CFIHS Link to comment Share on other sites More sharing options...
CFIHS Posted August 14, 2013 Share Posted August 14, 2013 (edited) Suggestion: Rename _FB_BoxReady to _FB_Ready. Edited August 14, 2013 by CFIHS Link to comment Share on other sites More sharing options...
Moderators Melba23 Posted August 14, 2013 Moderators Share Posted August 14, 2013 CFIHS,Could you please make your posts a little less cryptic. For example, is the one above a suggestion, a requirement or what? M23 Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind Open spoiler to see my UDFs: Spoiler ArrayMultiColSort ---- Sort arrays on multiple columnsChooseFileFolder ---- Single and multiple selections from specified path treeview listingDate_Time_Convert -- Easily convert date/time formats, including the language usedExtMsgBox --------- A highly customisable replacement for MsgBoxGUIExtender -------- Extend and retract multiple sections within a GUIGUIFrame ---------- Subdivide GUIs into many adjustable framesGUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView itemsGUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeViewMarquee ----------- Scrolling tickertape GUIsNoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxesNotify ------------- Small notifications on the edge of the displayScrollbars ----------Automatically sized scrollbars with a single commandStringSize ---------- Automatically size controls to fit textToast -------------- Small GUIs which pop out of the notification area Link to comment Share on other sites More sharing options...
Allow2010 Posted October 11, 2013 Author Share Posted October 11, 2013 (edited) @CFIHS Ahh i see, thank you...but some more text would have been helpful.-) Edited October 12, 2013 by Allow2010 Link to comment Share on other sites More sharing options...
Allow2010 Posted October 11, 2013 Author Share Posted October 11, 2013 added this (yet untestet and not yet on the files in post 1) ;ping the box to see if we can contact it Func _FB_BoxReady() Return _FB_Ready() EndFunc ;==>_FB_BoxReady Func _FB_Ready() $result = Ping($fritzbox_ip_or_name) If @error Then Return 0 Else Return 1 EndIf EndFunc ;==>_FB_BoxReady Func _FB_GetFWVersion() $aSS = StringSplit(_WinHttpSimpleRequest($hConnect, "GET", "/cgi-bin/system_status"), "-") $sFirmwareversion = StringTrimLeft($aSS[8], 2) Return $sFirmwareversion EndFunc Func _FB_IsLUA () $sFirmwareversion= _FB_GetFWVersion() If $sFirmwareversion > 0522 Then Return 1 Else Return 0 EndIf EndFunc ;==>_FB_IsLUA Link to comment Share on other sites More sharing options...
reeky Posted October 20, 2013 Share Posted October 20, 2013 (edited) Hello, its a very nice script. Thanks alot. Is there a possibility to change the settings of port forwarding? I want to add some ports and sometimes I want to edit some entries. How can I do this? I think you can use md5 crypted passwords in the ini file. So you make the script secure. Can you fix it in a newer version? Can you also add a list with all tested boxes? I'm using fritzbox 7312 with FRITZ!OS 05.51 and firmware-version: 117.05.51 . The standard example-script runs successfully on this box. Edited October 20, 2013 by reeky Link to comment Share on other sites More sharing options...
rewe Posted October 25, 2013 Share Posted October 25, 2013 Hello...very interesting! Thanks a lot! I tried to get the current connected devices on my Fritz Box (6360): sth. like: net/network_user_devices.lua Can you help me? Thanks a lot Reinhold Link to comment Share on other sites More sharing options...
sputnik089 Posted October 28, 2013 Share Posted October 28, 2013 I love your script! Do you have an idea how to get the support information file? The GUI way would be to call http://fritz.box/support.lua and then hit the button to create that info file. It takes some time to download but in there is all the information I would need to get the information of my boxes. I tried to understand your libraries, but did not succeed Any help would be great. THANKS Sputnik089 Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now