h4rithdpentest

$Target variables

Set it once. Every <IP>, <USER> or <DOMAIN> placeholder in the notes is rewritten live, and the copy buttons copy your values.

Stored in this browser only
h4rithd.com ↗

13Languages

.Net

Read
1 min
Blocks
7
Updated
Target

01 C#

  • Basic
csharpfilename.cs12 lines
filename.cs
using System;
namespace h4rithd
{
class welcome
{
static void Main(string[] args)
{
Console.WriteLine("welcome to h4rithd.com\r\n");
}
}
}
  • Complie
bash8 lines
## ------------------| Choose version
dir dir c:\Windows\Microsoft.NET\Framework64\v*
dir c:\Windows\Microsoft.NET\Framework\v*
## ------------------| Complie
c:\Windows\Microsoft.NET\Framework64\v4.0.30319\csc.exe filename.cs
dir ! find "filename.exe"
.\filename.exe
  • Debug
csharp13 lines
## ------------------| Debug comments
using System.Diagnostics;
static void Main(string[] args)
{
Debug.Print("Debug");
}
## ------------------| Console output
Console.WriteLine("Debug");
System.Console.WriteLine("Debug");
## ------------------| Message Box
MessageBox.Show("message", "title");

02 DotNet Core

02.1 Getting Started

bash8 lines
## ------------------| Installation on KaliLinux
wget https://packages.microsoft.com/config/debian/12/packages-microsoft-prod.deb -O packages-microsoft-prod.deb
sudo dpkg -i packages-microsoft-prod.deb
rm packages-microsoft-prod.deb
sudo apt-get update
sudo apt-get install -y dotnet-sdk-X.0 ### change the X value as 4,5,6,7,8,9...
sudo apt-get install -y dotnet-runtime-X.0 ### change the X value as 4,5,6,7,8,9...
sudo apt-get install -y aspnetcore-runtime-X.0 ### change the X value as 4,5,6,7,8,9...

02.2 Create Applications

CLI Application

bash10 lines
## ------------------| Create project
dotnet new console -o cliapp
## ------------------| Run the appllication
cd cliapp
dotnet run
## ------------------| Build
dotnet build -c release
dotnet build -c debug

ASP.NET Core

bash10 lines
## ------------------| Create project
dotnet new webapp --output aspnetcoreapp --no-https
## ------------------| Run the appllication
cd aspnetcoreapp
dotnet run
## ------------------| Build
dotnet build -c release
dotnet build -c debug

DLL Application

bash10 lines
## ------------------| Create project
dotnet new classlib -n dllapp
## ------------------| Add Packages
dotnet add package Microsoft.AspNetCore.Components --version 6.0.0
dotnet add package Microsoft.AspNetCore.Components.Web --version 6.0.0
## ------------------| Build
dotnet build -c release
dotnet build -c debug