!C99Shell v.2.1 [PHP 7 Update] [1.12.2019]!

Software: Apache/2.2.8 (Ubuntu) PHP/5.2.4-2ubuntu5.12 with Suhosin-Patch mod_ssl/2.2.8 OpenSSL/0.9.8g. PHP/5.2.4-2ubuntu5.12 

uname -a: Linux forum.circlefusion.com 2.6.24-19-server #1 SMP Wed Jun 18 15:18:00 UTC 2008 i686 

uid=33(www-data) gid=33(www-data) groups=33(www-data) 

Safe-mode: OFF (not secure)

/usr/share/denyhosts/DenyHosts/   drwxr-xr-x
Free 11.24 GB of 97.11 GB (11.58%)
Home    Back    Forward    UPDIR    Refresh    Search    Buffer    Encoder    Tools    Proc.    FTP brute    Sec.    SQL    PHP-code    Update    Feedback    Self remove    Logout    


Viewing file:     counter.py (1.62 KB)      -rw-r--r--
Select action/file-type:
(+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |

import time
import logging

debug = logging.getLogger("counter").debug

class CounterRecord:
    def __init__(self, count=0, date=None):
        self.__count = count
        if not date:
            self.__date = time.asctime()
        else:
            self.__date = date

    def __str__(self):
        return "%d:%s" % (self.__count, self.__date)

    def __repr__(self):
        return "CountRecord <%d - %s>" % (self.__count, self.__date)

    def __add__(self, increment):
        self.__count += increment
        self.__date = time.asctime()
        return self

    def get_count(self):
        return self.__count

    def get_date(self):
        return self.__date

    def reset_count(self):
        self.__count = 0
        
    def age_count(self, age):
        cutoff = long(time.time()) - age
        epoch = time.mktime(time.strptime(self.__date))
        #debug("cutoff : %d", cutoff)
        #debug("epoch  : %d", epoch)
        if cutoff > epoch:
            self.__count = 0
        

class Counter(dict):
    """
     Behaves like a dictionary, except that if the key isn't found, 0 is returned
     rather than an exception.  This is suitable for situations like:
         c = Counter()
         c['x'] += 1
    """
    def __init__(self):
        dict.__init__(self)

    def __getitem__(self, k):
        try:
            return dict.__getitem__(self, k)
        except:
            count_rec = CounterRecord(0)
            #debug("%s - %s", k, count_rec)
            self.__setitem__(k, count_rec)
            #debug("dict: %s", dict.values(self))
            #debug("count_rec: %s", count_rec)
            return count_rec


        

:: Command execute ::

Enter:
 
Select:
 

:: Search ::
  - regexp 

:: Upload ::
 
[ Read-Only ]

:: Make Dir ::
 
[ Read-Only ]
:: Make File ::
 
[ Read-Only ]

:: Go Dir ::
 
:: Go File ::
 

--[ c99shell v.2.1 [PHP 7 Update] [1.12.2019] maintained by KaizenLouie and updated by cermmik | C99Shell Github (MySQL update) | Generation time: 0.0067 ]--