Skip to content

Instantly share code, notes, and snippets.

View ShutovKS's full-sized avatar
:octocat:
Programming

Kirill ShutovKS

:octocat:
Programming
View GitHub Profile
@ShutovKS
ShutovKS / README.md
Created February 2, 2026 22:09
WireGuard DPI Bypass (macOS) — pre-UDP before handshake

WireGuard DPI Bypass (macOS) — pre-UDP before handshake

Иногда провайдер/DPI распознаёт “первый” WireGuard handshake и начинает резать/душить соединение (часто выглядит как: handshake то появляется, то пропадает, либо “пакеты отправляются, но не приходят”).

Решение: перед включением туннеля отправить любой UDP-пакет на Endpoint с того же локального порта, который будет использовать WireGuard (ListenPort). Это “ломает” сигнатуру DPI на старте, и WireGuard обычно подключается стабильно.


Что нужно

@ShutovKS
ShutovKS / README.md
Last active February 2, 2026 23:01
WireGuard DPI Bypass (Windows) — pre-UDP before handshake

WireGuard DPI Bypass (Windows) — Pre-UDP helper (no tunnel control)

Иногда провайдер/DPI распознаёт WireGuard по первому handshake и начинает “душить” соединение.
Обход: перед включением туннеля отправить любой UDP-пакет на Endpoint с того же локального порта, который использует WireGuard (ListenPort).

Этот репозиторий/гист содержит только helper для pre-UDP.
Он НЕ останавливает/устанавливает/запускает туннель — вы включаете туннель в WireGuard GUI как обычно.


@ShutovKS
ShutovKS / readme.md
Last active December 13, 2025 23:54
Change Commit Time (Last Local Commit)

🇬🇧 Change Commit Time (Last Local Commit)

If you've already made a local commit, but want to backdate it (change author and committer time), you can do it with git commit --amend using environment variables.

🔧 Steps

  1. Set the desired date and timezone:

export GIT_AUTHOR_DATE="2025-05-20T08:30:00+0300"

@ShutovKS
ShutovKS / ProjectManagement.cs
Last active January 6, 2025 11:00
Project management in the form of a "state machine".
#region
using System;
using System.Collections.Generic;
using System.Threading;
using Cysharp.Threading.Tasks;
using Zenject;
#endregion
@ShutovKS
ShutovKS / Extensions.cs
Created June 15, 2024 14:36
Getting random value from enum in C#
public static class Extensions
{
public static int RandomIndex<T>() where T : Enum
{
var values = Enum.GetValues(typeof(T));
return new System.Random().Next(values.Length);
}
}
@ShutovKS
ShutovKS / MonoBehaviourSingletonExample.cs
Created May 6, 2024 17:02
Example Singleton "MonoBehaviour"
using UnityEngine;
public class MonoBehaviourSingletonExample : MonoBehaviour
{
public static MonoBehaviourSingletonExample Instance => _instance ?? Initialize();
private static MonoBehaviourSingletonExample _instance;
private static MonoBehaviourSingletonExample Initialize()
{
var instance = new GameObject();
@ShutovKS
ShutovKS / ExampleQuit.cs
Last active May 15, 2024 19:19
Quitting the game in Unity
using UnityEngine;
public class ExampleQuit
{
public static void Quit()
{
#if UNITY_EDITOR
UnityEditor.EditorApplication.isPlaying = false;
#elif UNITY_WEBGL
// Link to the website page where you want to go after clicking the exit button
@ShutovKS
ShutovKS / UnityMainThreadManager.cs
Created April 20, 2024 17:38
Unity main thread manager
using System;
using System.Collections;
using System.Collections.Generic;
using System.Threading.Tasks;
using UnityEngine;
public class UnityMainThreadManager : MonoBehaviour
{
private static readonly Queue<Action> executionQueue = new();
private static UnityMainThreadManager _instance;
@ShutovKS
ShutovKS / BuildTargetConverter.cs
Last active April 20, 2024 17:48
Converter for Unity, BuildTargetGroup => BuildTarget & BuildTarget => BuildTargetGroup
using UnityEditor;
public static class BuildTargetConverter
{
public static BuildTarget ToBuildTarget(this BuildTargetGroup buildTargetGroup)
{
return buildTargetGroup switch
{
BuildTargetGroup.GameCoreXboxOne => BuildTarget.GameCoreXboxOne,
BuildTargetGroup.EmbeddedLinux => BuildTarget.EmbeddedLinux,
@ShutovKS
ShutovKS / .gitignore
Last active January 6, 2025 10:58
Unity gitignore
### Unity .gitignore template
# This .gitignore file should be placed at the root of your Unity project directory
# Unity-specific
/[Ll]ibrary/
/[Tt]emp/
/[Oo]bj/
/[Ll]ogs/
/[Uu]ser[Ss]ettings/