Hi,
ich möchte per Event Monitor ein notify (o.ä.) anlegen (Button create/modify device).
Wenn ich (komplette Zeile ist unterlegt) den create-button drücke und das z.B. notify anlegen lassen will, lande ich auf
http://<fhemip>:8083/fhem?detail=undefined
Hier im "WEB" hab ich alles allowed (weil ich ich auch alles machen will, die anderen WEB-instanzen sind kastriert vom allowed-umfang):
define allowed_WEB allowed
attr allowed_WEB allowedCommands perl,grep,style%20list,apptime,attr,backup,cancel,cmdalias,configdb,copy,count,createlog,CULflash,define,defmod,delete,deleteattr,deletefile,deletereading,displayattr,fhemdebug,fheminfo,get,help,HMtemplate,IF,include,inform,JsonList,JsonList2,list,modify,MSG,notice,quit,reload,rename,rereadcfg,restore,save,set,setdefaultattr,setReading,setstate,shutdown,sleep,trigger,update,usb,version,xmllist,setReadingdesc,setreadingdesc,setreading
attr allowed_WEB basicAuth <blablabla>
attr allowed_WEB validFor WEB
Wenn ich das Attribut allowedCommands lösche, funktioniert's (eine Alternative - weil ich hier eh alles machen möcht)
Welchen allowedCommand muss ich hierfür ins attr noch einfügen, damit creaty/modify aus dem Event Monitor nutzbar ist?
Gibt es mit verbose=5 einen Logeintrag?
Was sagt die JavaScript-Konsole beim Aufruf des Buttons?
Konsole bei button-press:
18:52:49.882 ERRMSG:Connection lost, trying a reconnect every 5 seconds.< fhemweb.js:492:5
18:52:50.465 Inform-channel opened (HTTP) with filter undefined fhemweb.js:492:5
18:52:50.585 Rcvd: fhemweb.js:492:5
attr WEB verbose 5:
2018.12.19 18:52:47 4: Connection accepted from WEB_192.168.50.27_38680
2018.12.19 18:52:47 4: WEB_192.168.50.27_38680 POST /fhem?cmd=jsonlist2%20.*%20TYPE&XHR=1&fwcsrf=csrf_743806445247486&fw_id=4464; BUFLEN:0
2018.12.19 18:52:47 3: Forbidden command jsonlist2 for WEB_192.168.50.27_38680
2018.12.19 18:52:47 1: stacktrace:
2018.12.19 18:52:47 1: main::allowed_Authorize called by fhem.pl (3603)
2018.12.19 18:52:47 1: main::CallFn called by fhem.pl (5380)
2018.12.19 18:52:47 1: main::Authorized called by fhem.pl (1205)
2018.12.19 18:52:47 1: main::AnalyzeCommand called by fhem.pl (1063)
2018.12.19 18:52:47 1: main::AnalyzeCommandChain called by ./FHEM/01_FHEMWEB.pm (2588)
2018.12.19 18:52:47 1: main::FW_fC called by ./FHEM/01_FHEMWEB.pm (863)
2018.12.19 18:52:47 1: main::FW_answerCall called by ./FHEM/01_FHEMWEB.pm (535)
2018.12.19 18:52:47 1: main::FW_Read called by fhem.pl (3603)
2018.12.19 18:52:47 1: main::CallFn called by fhem.pl (726)
2018.12.19 18:52:47 4: authorize WEB/cmd/jsonlist2: allowed_WEB returned prohibited
2018.12.19 18:52:47 4: WEB: /fhem?cmd=jsonlist2%20.*%20TYPE&XHR=1&fwcsrf=csrf_743806445247486&fw_id=4464 / RL:49 / text/plain; charset=UTF-8 / Content-Encoding: gzip
/
2018.12.19 18:52:49 4: WEB_192.168.50.27_38680 POST /fhem?cmd= &XHR=1&fwcsrf=csrf_743806445247486&fw_id=4464; BUFLEN:0
2018.12.19 18:52:49 4: WEB: /fhem?cmd= &XHR=1&fwcsrf=csrf_743806445247486&fw_id=4464 / RL:20 / text/plain; charset=UTF-8 / Content-Encoding: gzip
/
2018.12.19 18:52:49 4: Connection closed for WEB_192.168.50.27_38670: EOF
2018.12.19 18:52:49 4: WEB_192.168.50.27_38680 GET /fhem?detail=undefined; BUFLEN:0
2018.12.19 18:52:50 4: WEB: /fhem?detail=undefined / RL:14086 / text/html; charset=UTF-8 / Content-Encoding: gzip
/
2018.12.19 18:52:50 4: WEB_192.168.50.27_38680 GET /fhem?XHR=1&inform=type=status;filter=undefined;since=1545241969;fmt=JSON&fw_id=4516×tamp=1545241970465; BUFLEN:0
Ich hab's:
2018.12.19 18:52:47 4: authorize WEB/cmd/jsonlist2: allowed_WEB returned prohibited
jsonlist2
für attr allowedCommands ergänzt
stand bei mir noch groß geschrieben drinnen:
JsonList,JsonList2
--> jetzt geht's
Danke für Tipp, konsole war's