fix typo in method name
authorStricted <info@stricted.de>
Thu, 3 Sep 2015 22:02:28 +0000 (00:02 +0200)
committerStricted <info@stricted.de>
Thu, 3 Sep 2015 22:02:28 +0000 (00:02 +0200)
SpeedportHybrid.class.php
lib/trait/Connection.class.php
lib/trait/CryptLib.class.php
lib/trait/Firewall.class.php
lib/trait/Login.class.php
lib/trait/Phone.class.php
lib/trait/System.class.php

index 95f1f0cc9629d03a8b8a9ddfaa323fdeb1023da2..14a07bd04163db48c0b02d9cd309b70526b58d24 100644 (file)
@@ -114,7 +114,7 @@ class SpeedportHybrid {
         * @param       integer $count
         * @return      array
         */
-       private function sentRequest ($path, $fields, $cookie = false, $count = 0) {
+       private function sendRequest ($path, $fields, $cookie = false, $count = 0) {
                $url = $this->url.$path.'?lang=en';
                $ch = curl_init();
                curl_setopt($ch, CURLOPT_URL, $url);
index 64b1ecb61fd1ea9b28ad4a1bb0ae7fa463aee3bc..4361d5d00f07d395558d5e4b87936cf151565256 100644 (file)
@@ -18,7 +18,7 @@ trait Connection {
                
                if ($status == 'online' || $status == 'offline') {
                        $fields = array('csrf_token' => 'nulltoken', 'showpw' => 0, 'password' => $this->hash, 'req_connect' => $status);
-                       $data = $this->sentRequest($path, $fields, true);
+                       $data = $this->sendRequest($path, $fields, true);
                        $data = $this->getValues($data['body']);
                        
                        if ($data['status'] == 'ok') {
@@ -48,7 +48,7 @@ trait Connection {
                        else if ($status == 'no') $status = '0';
                        
                        $fields = array('csrf_token' => $this->token, 'use_lte' => $status);
-                       $data = $this->sentEncryptedRequest($path, $fields, true);
+                       $data = $this->sendEncryptedRequest($path, $fields, true);
                        
                        // debug only
                        return $data;
@@ -68,7 +68,7 @@ trait Connection {
                
                $path = 'data/modules.json';
                $fields = array('csrf_token' => $this->token, 'lte_reconn' => '1');
-               $data = $this->sentEncryptedRequest($path, $fields, true);
+               $data = $this->sendEncryptedRequest($path, $fields, true);
                
                return $data['body'];
        }
index ce32bb75f62482ef9972cdd312477cbc3ed53644..1ff94990a142301f7bf3b624ea973a07f791481e 100644 (file)
@@ -13,10 +13,10 @@ trait CryptLib {
         * @param       string  $cookie
         * @return      array
         */
-       private function sentEncryptedRequest ($path, $fields, $cookie = false) {
+       private function sendEncryptedRequest ($path, $fields, $cookie = false) {
                $count = count($fields);
                $fields = $this->encrypt(http_build_query($fields));
-               return $this->sentRequest($path, $fields, $cookie, $count);
+               return $this->sendRequest($path, $fields, $cookie, $count);
        }
        
        /**
index 3fbe070fcab38332d7a7493d59d67cd84dd37482..e4c9dba2331de7327daeadc60b115b1d1b8be772 100644 (file)
@@ -38,7 +38,7 @@ trait Firewall {
                                                'deleteEntry' => 'delete'
                                                );
                
-               $data = $this->sentRequest($path, $fields, true);
+               $data = $this->sendRequest($path, $fields, true);
                $data = $this->getValues($data['body']);
                
                if ($data['status'] == 'ok') {
index 545a83fdb52836e51848fd8d64256a88df872bbf..09acc275364845a217a802f3fb533add1a01b5d1 100644 (file)
@@ -47,7 +47,7 @@ trait Login {
                $path = 'data/Login.json';
                $this->hash = hash('sha256', $this->challenge.':'.$password);
                $fields = array('csrf_token' => 'nulltoken', 'showpw' => 0, 'password' => $this->hash);
-               $data = $this->sentRequest($path, $fields);
+               $data = $this->sendRequest($path, $fields);
                $json = $this->getValues($data['body']);
                
                if (isset($json['login']) && $json['login'] == 'success') {
@@ -72,7 +72,7 @@ trait Login {
        private function getChallenge () {
                $path = 'data/Login.json';
                $fields = array('csrf_token' => 'nulltoken', 'showpw' => 0, 'challengev' => 'null');
-               $data = $this->sentRequest($path, $fields);
+               $data = $this->sendRequest($path, $fields);
                $data = $this->getValues($data['body']);
                
                if (isset($data['challengev']) && !empty($data['challengev'])) {
@@ -101,7 +101,7 @@ trait Login {
                
                $path = 'data/SecureStatus.json';
                $fields = array();
-               $data = $this->sentRequest($path, $fields, true);
+               $data = $this->sendRequest($path, $fields, true);
                $data = $this->getValues($data['body']);
                
                if ($data['loginstate'] != 1) {
@@ -125,7 +125,7 @@ trait Login {
                
                $path = 'data/Login.json';
                $fields = array('csrf_token' => $this->token, 'logout' => 'byby');
-               $data = $this->sentRequest($path, $fields, true);
+               $data = $this->sendRequest($path, $fields, true);
                $data = $this->getValues($data['body']);
                if ((isset($data['status']) && $data['status'] == 'ok') && $this->checkLogin(false) === false) {
                        // reset challenge and session
@@ -150,7 +150,7 @@ trait Login {
                
                $path = 'html/content/overview/index.html';
                $fields = array();
-               $data = $this->sentRequest($path, $fields, true);
+               $data = $this->sendRequest($path, $fields, true);
                
                $a = explode('csrf_token = "', $data['body']);
                $a = explode('";', $a[1]);
index 618b88c61a9fb1b8e38a9da7d3aa77ee0c7b2bb2..d55bd43db6a1a2ad28265dfd5b134b4691d3c309 100644 (file)
@@ -48,7 +48,7 @@ trait Phone {
                                                'phonebook_number_m' => $mobile
                                                );
                
-               $data = $this->sentRequest($path, $fields, true);
+               $data = $this->sendRequest($path, $fields, true);
                $data = $this->getValues($data['body']);
                
                if ($data['status'] == 'ok') {
@@ -91,7 +91,7 @@ trait Phone {
                                                'deleteEntry' => 'delete'
                                                );
                
-               $data = $this->sentRequest($path, $fields, true);
+               $data = $this->sendRequest($path, $fields, true);
                $data = $this->getValues($data['body']);
                
                if ($data['status'] == 'ok') {
index cf5849377b4befba89743323aa3235a8d1cacb7f..4cd4c6e3befb9c99cde0b1e4eecaa4dcbb9a618e 100644 (file)
@@ -28,7 +28,7 @@ trait System {
                
                $path = 'data/'.$file.'.json';
                $fields = array();
-               $data = $this->sentRequest($path, $fields, true);
+               $data = $this->sendRequest($path, $fields, true);
                
                return $data['body'];
        }
@@ -61,7 +61,7 @@ trait System {
                
                $path = 'data/resetAllSetting.json';
                $fields = array('csrf_token' => 'nulltoken', 'showpw' => 0, 'password' => $this->hash, 'reset_all' => 'true');
-               $data = $this->sentRequest($path, $fields, true);
+               $data = $this->sendRequest($path, $fields, true);
                
                return $data['body'];
        }
@@ -77,7 +77,7 @@ trait System {
                
                $path = 'data/checkfirmware.json';
                $fields = array('checkfirmware' => 'true');
-               $data = $this->sentRequest($path, $fields, true);
+               $data = $this->sendRequest($path, $fields, true);
                
                return $data['body'];
        }
@@ -92,7 +92,7 @@ trait System {
                
                $path = 'data/Reboot.json';
                $fields = array('csrf_token' => $this->token, 'reboot_device' => 'true');
-               $data = $this->sentEncryptedRequest($path, $fields, true);
+               $data = $this->sendEncryptedRequest($path, $fields, true);
                $data = $this->getValues($data['body']);
                
                if ($data['status'] == 'ok') {