public static void Attack(string attack, string attackdesc, ToolTipIcon icon, bool isattack) { KavprotVoice.SpeakAsync(attackdesc); if (!SettingsManager.Silence) { if (isattack) { AVEngine.AlertMaximalinfection(); } AVEngine.EventsManager.CallNotify(attack, attackdesc, icon); } }
public static void Infected(Virus infection) { KavprotVoice.SpeakAsync("This file was infected by " + infection.Name); AVEngine.EventsManager.CallVirusDetected(); KavprotRemoteControl.SendPacket(SettingsManager.ApplicationAdress, SettingsManager.MobileAdress, KavprotRemoteControl.BuildARCPacket("SHOWTEXT", "ALDATA", SettingsManager.ApplicationAdress, "0005", Encoding.UTF8.GetBytes("File name : " + infection.Location + " \r\n Infection : " + infection.Name))); KavprotManager.LastThreat = infection.Name; if (SettingsManager.Silence) { if (infection.Scanner.Name == "HASH-TYPE-SCANNER") { Alert.Attack("Virus Detected " + infection.Name, "Kavprot smart security detected a virus by the Hash scan system (" + infection.Location + "). sometimes false-positive alert can happen by any antivirus software for more informations visit : http://www.arsslensoft.tk/AVL/FPAlert.html", ToolTipIcon.Warning, true); } else { Quarantine.Store(infection.Location, infection.Name); } } else { if (infection.Name != "KavProtSensor.UnPackableArchive") { if (SettingsManager.Silence) { if (infection.Location.Contains(Environment.SystemDirectory)) { AVEngine.AlertVirus(); InfectionFrm inf = new InfectionFrm(infection); inf.ShowDialog(); } else { Quarantine.Store(infection.Location, infection.Name); } } else { AVEngine.AlertVirus(); InfectionFrm inf = new InfectionFrm(infection); inf.ShowDialog(); } } } }
private void fullscanlist_ItemAdded(object sender, EventArgs e) { fullscanlist.Refresh(); AVEngine.AlertVirus(); }
public static void Initialize(KavprotInitialization init) { try { // init settings SettingsManager.Initialize(); if (SettingsManager.TurboMode) { AsyncInvoke ainv = new AsyncInvoke(KavprotVoice.Initialize); ainv.BeginInvoke(null, null); // Activation.Initialize(); //if (!Activation.Expired) //{ if (init == KavprotInitialization.Full) { // init monitors AsyncInvoke inv = new AsyncInvoke(InitMonitors); inv.BeginInvoke(null, null); // init engine AVEngine.Initialize(SettingsManager.Scansense); if (SettingsManager.KavprotRemoteControl) { AsyncInvoke dinv = new AsyncInvoke(KavprotRemoteControl.Init); dinv.BeginInvoke(null, null); AsyncInvoke tinv = new AsyncInvoke(KavprotRemoteControl.ReceiveDataFromMobile); tinv.BeginInvoke(null, null); } AntivirusState.SetProtection(true); } else { // init engine AVEngine.Initialize(SettingsManager.Scansense); } //} //else //{ // MessageBox.Show("Kavprot will be closed after you click ok", "Activation", MessageBoxButtons.OK, MessageBoxIcon.Warning); // ShutDown(); //} } else { KavprotVoice.Initialize(); //Activation.Initialize(); //if (!Activation.Expired) //{ if (init == KavprotInitialization.Full) { // init monitors InitMonitors(); // init engine AVEngine.Initialize(SettingsManager.Scansense); if (SettingsManager.KavprotRemoteControl) { KavprotRemoteControl.Init(); AsyncInvoke inv = new AsyncInvoke(KavprotRemoteControl.ReceiveDataFromMobile); inv.BeginInvoke(null, null); } AntivirusState.SetProtection(true); } else { // init engine AVEngine.Initialize(SettingsManager.Scansense); } //} //else //{ // MessageBox.Show("Kavprot will be closed after you click ok", "Activation", MessageBoxButtons.OK, MessageBoxIcon.Warning); // ShutDown(); //} } } catch { } }