public IActionResult RestartTor() { if (User.Claims.FirstOrDefault(c => c.Type == "http://schemas.microsoft.com/ws/2008/06/identity/claims/role").Value == "User") { return(RedirectToAction(nameof(HomeController.Index), "Home")); } ConfigTor.KillTor(); ConfigTor.StartTor(); return(Content("Ok")); }
static void Main(string[] args) { Console.WriteLine("Starting..."); ConfigTor.StartTor(); }