 import flash.events.SecurityErrorEvent;
 import flash.net.Socket;
 import flash.utils.ByteArray;
+import flash.utils.setInterval;
 
 /* An instance of a client-relay connection. */
 class ProxyPair


        private var fac_addr:Object;

        [Embed(source="badge.png")]
        private var BadgeImage:Class;

        public function puts(s:String):void
        {


    // Parent swfcat, for UI updates.
    private var ui:swfcat;
    
    // Proxy transfer rate limit in KB/s
    private var rate_limit:uint;
    
    // Default limit is 10KB/s
    private const DEFAULT_RATE_LIMIT:uint = 10000;
    
    private var curr_rate:Number;
    private var historical_rate:Number;
    private var lifetime:uint;
    
    // in milliseconds
    private const DEFAULT_RATE_TIMEOUT:uint = 1000;

    private function log(msg:String):void
    {
