Пример #1
0
 void saap_UpdatedArpCache()
 {
     if (listBox1.InvokeRequired)
     {
         cache = saap.GetCache();
         System.Threading.ThreadStart ts = new System.Threading.ThreadStart(saap_UpdatedArpCache);
         listBox1.Invoke(ts);
     }
     else
     {
         listBox1.Items.Clear();
         foreach (KeyValuePair <IPAddress, byte[]> i in cache)
         {
             listBox1.Items.Add(BitConverter.ToString(i.Value).Replace("-", "") + " -> " + i.Key.ToString());
         }
     }
 }
Пример #2
0
 public ArpPoisoningProtection(ARPPP saap)
 {
     if (null != saap)
     {
         this.saap = saap;
         cache = saap.GetCache();
         saap.UpdatedArpCache += new System.Threading.ThreadStart(saap_UpdatedArpCache);
         InitializeComponent();
         saap_UpdatedArpCache();
     }
 }
Пример #3
0
 public ArpPoisoningProtection(ARPPP saap)
 {
     if (null != saap)
     {
         this.saap             = saap;
         cache                 = saap.GetCache();
         saap.UpdatedArpCache += new System.Threading.ThreadStart(saap_UpdatedArpCache);
         InitializeComponent();
         saap_UpdatedArpCache();
     }
 }