aboutsummaryrefslogtreecommitdiffstats
path: root/mod/pubsub.php
diff options
context:
space:
mode:
Diffstat (limited to 'mod/pubsub.php')
-rw-r--r--mod/pubsub.php5
1 files changed, 5 insertions, 0 deletions
diff --git a/mod/pubsub.php b/mod/pubsub.php
index 5d8ea2ed7..f829eb4d9 100644
--- a/mod/pubsub.php
+++ b/mod/pubsub.php
@@ -91,6 +91,11 @@ function pubsub_post(&$a) {
logger('pubsub: user-agent: ' . $_SERVER['HTTP_USER_AGENT'] );
logger('pubsub: data: ' . $xml, LOGGER_DATA);
+ if(! stristr($xml,'<?xml')) {
+ logger('pubsub_post: bad xml');
+ hub_post_return();
+ }
+
$nick = (($a->argc > 1) ? notags(trim($a->argv[1])) : '');
$contact_id = (($a->argc > 2) ? intval($a->argv[2]) : 0 );