次のコードを使用して、アプリケーションの自動開始を設定しています。
using (RegistryKey rk = Registry.CurrentUser.OpenSubKey("SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Run", true))
{
rk.SetValue("Application", Application.ExecutablePath); //add autostart
}
コンパイルすると、「Trojan:Win32/Bearfoos.A!ml」と「Trojan:Win32/Azden.A!cl」が検出されたため、Windows Defender は即座にファイルを削除します
私はすでにこれらの行を削除しようとしましたが、成功しませんでした。これは、自動起動アプリケーションを作成する簡単な方法の 1 つです。