Skip to content

Commit

Permalink
limit the update-check.cgi to parse for cmd=download and not parse ar…
Browse files Browse the repository at this point in the history
…bitrary query string options.
  • Loading branch information
jens-maus committed Jun 17, 2022
1 parent a7af53e commit a701c57
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 8 deletions.
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
# XML-API CCU Addon

[![Release](https://img.shields.io/github/release/hobbyquaker/XML-API.svg)](https://github.com/hobbyquaker/XML-API/releases/latest)
[![Downloads](https://img.shields.io/github/downloads/hobbyquaker/XML-API/latest/total.svg)](https://github.com/hobbyquaker/XML-API/releases/latest)
[![Issues](https://img.shields.io/github/issues/hobbyquaker/XML-API.svg)](https://github.com/hobbyquaker/XML-API/issues)
[![Release](https://img.shields.io/github/release/homematic-community/XML-API.svg)](https://github.com/homematic-community/XML-API/releases/latest)
[![Downloads](https://img.shields.io/github/downloads/homematic-community/XML-API/latest/total.svg)](https://github.com/homematic-community/XML-API/releases/latest)
[![Issues](https://img.shields.io/github/issues/homematic-community/XML-API.svg)](https://github.com/homematic-community/XML-API/issues)
[![License](https://img.shields.io/badge/license-GPL%203.0-green.svg)](https://opensource.org/licenses/GPL-3.0)

A HomeMatic CCU Addon implementing a xml request functionality as an interface to all homematic deviced available to a CCU device. This addon provides useful scripts that can be accessed via a HTTP request to a CCU device and allows to query and set all e.g. room- and devicetype names.
Expand Down
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
1.21
1.22
9 changes: 5 additions & 4 deletions xmlapi/update-check.cgi
Original file line number Diff line number Diff line change
@@ -1,14 +1,15 @@
#!/bin/tclsh

set checkURL "https://raw.githubusercontent.com/hobbyquaker/XML-API/master/VERSION"
set downloadURL "https://github.com/hobbyquaker/XML-API/releases/latest"
set checkURL "https://raw.githubusercontent.com/homematic-community/XML-API/master/VERSION"
set downloadURL "https://github.com/homematic-community/XML-API/releases"

catch {
set input $env(QUERY_STRING)
set pairs [split $input &]
foreach pair $pairs {
if {0 != [regexp "^(\[^=]*)=(.*)$" $pair dummy varname val]} {
set $varname $val
if {$pair == "cmd=download"} {
set cmd "download"
break
}
}
}
Expand Down

0 comments on commit a701c57

Please sign in to comment.