Skip to content

Instantly share code, notes, and snippets.

View VityaSchel's full-sized avatar
🏳️‍🌈
pride

Viktor Shchelochkov VityaSchel

🏳️‍🌈
pride
View GitHub Profile
@VityaSchel
VityaSchel / run-this-with-bun-sh.ts
Last active July 2, 2024 22:45
Брутфорс кодового слова на zp.midpass.ru Запуск: bun run-this-with-bun-sh.ts
import crypto from 'node:crypto'
// вместо 4 подставьте предполагаемую длину пароля
const passwordLength = 4
// подставьте строку из localStorage -> DecryptTestMessage
const encryptedText = 'U2FsdGVkX19qOI7LCQdLXzD9HpujeJl7mNCrTNMrVzqWCKd7IcjTdg=='
function decrypt(password: Buffer) {
let bytes = Buffer.concat([password, salt])
@VityaSchel
VityaSchel / teachers.js
Last active January 3, 2026 16:05
Парсер сайта колледжа связи https://ks.psuti.ru/ и https://lk.ks.psuti.ru/
if(window.location.href !== 'https://ks.psuti.ru/about/teachers.html') throw new Error('Перейдите на страницу https://ks.psuti.ru/about/teachers.html')
const table = document.querySelector('form[action="https://ks.psuti.ru/about/teachers.html"')
const limitField = table.querySelector('select[name="limit"]')
if(limitField.options[limitField.selectedIndex].text !== 'Все') throw new Error('Выберете "Все" в "Количество строк"')
const teachers = Array.from(table.querySelectorAll('tbody > tr > td:last-child > a')).slice(1)
const getTeacherInfo = (url) => {
@VityaSchel
VityaSchel / macos-widget-to-ring-samsung-phones.md
Last active January 3, 2026 16:06
MacOS widget to ring samsung phones, reverse engineering samsung's smartthings find

hello gays

today we have a list of things to do to develop a widget for macos to ring samsung phones like on smartthings find

since no one developed it yet and I don't want to do that I'm just gonna leave it there for anyone and wait for anyone to develop it or tell me it exists

UPDATE: I actually was so bored I developed and published it: https://github.com/VityaSchel/samsung-pinger

number 1

@VityaSchel
VityaSchel / preview.md
Last active August 29, 2023 06:29
Show all IDs on screen in At Dead of Night or any other webpage (oneliner)
We couldn’t find that file to show.
@VityaSchel
VityaSchel / README.md
Created August 22, 2023 20:20
Люди о войне

Скрипт для получения списков с сайта https://human-nonhuman.info/

Получите два списка: humans и nonhumans

@VityaSchel
VityaSchel / README.md
Last active May 31, 2026 11:53
Reset Steam achievements on MacOS without SAM (updated for macOS 26 and 2025)

This took me a while to figure out, so here's all you need to know:

  1. In order to clear an achievement we're going to use Steam's client secret console and achievement_clear command
  2. You'll need the game ID (appid, number like 123456) and an achievement id (text like ACHIEVEMENT_NAME) in order to lock it
  3. Since there is no "clear all achievements" command, we're going to use keyboard simulation to paste a long list of commands to the Steam's client console

Steps to reset all achievements for a Steam game

  1. Open https://steamdb.info/ and find your game in the search
  2. Open "Achievements" page
  3. Open your browser's DevTools and paste this script into the browser console on SteamDB page:
@VityaSchel
VityaSchel / index.html
Created April 30, 2023 20:13
Sucklabs browser matrix generator
<!DOCTYPE html>
<html lang="ru" dir="ltr">
<head>
<meta charset="utf-8">
<title>Sucklabs browser matrix generator</title>
</head>
<body>
<form id='form' style='display: flex; flex-direction: column; width: 182px;'>
<textarea name="name" rows="8" cols="10" id='text'>chrome: 95 windows 11, 95 windows 10, 95 windows8 8.1, 95 mac 11.4, 95 linux *, 94 windows 11, 94 windows 10, 94 windows8 8.1, 94 mac 11.4, 94 linux *, 93 windows 11, 93 windows 10, 93 windows8 8.1, 93 mac 11.4, 93 linux *, 93 android 11, 93 android 10
opera: 80 windows 11, 80 windows 10, 80 windows8 8.1, 80 windows8 8, 80 mac 11.4, 80 linux *, 63 android 11, 63 android 10
@VityaSchel
VityaSchel / telegram-mtproto-entities-to-html.ts
Created January 8, 2023 18:39
Function that accepts clear text with Telegram Core API styled text message entities and converts it to HTML.
import { Api } from 'telegram'
// gram.js format
const insert = (text: string, start: number, substring: string) => {
return text.substring(0, start) + substring + text.substring(start, text.length)
}
export function styleEntitiesToHTML(text: string, entities: Api.TypeMessageEntity[]): string {
let html = text
const tags = {
@VityaSchel
VityaSchel / animated-svg-recorder.js
Last active January 3, 2026 16:06
Record animated SVG on websites (animated by lottie and similar tools)
let recordedChanges = []
let startRecordingSVG = () => { recordedChanges = [] }
let stopRecordingSVG = () => { console.log(JSON.stringify(recordedChanges)) }
let observer = new MutationObserver(mutationRecords => {
for(const record of mutationRecords) {
if(record.attributeName === 'd') {
recordedChanges.push(record.target.getAttribute('d'))
}
}
@VityaSchel
VityaSchel / README.md
Last active February 4, 2026 11:46
Example of reading another process memory in Go without knowing base address

You can find explanation here: https://stackoverflow.com/questions/71716646/golang-calculate-address-of-another-process-memory-based-on-process-handle-and-o/72674927#72674927 This is actually my answer posted by my friend because SO doesn't allow you to reclaim your own bounty :)

It's not perfect because I don't know Go and you can definetely replace windows.OpenProcess with kernel32.OpenProcess but I'm too tired to experiment. It just works!

Also keep in mind that this code only works if you have running TJoC:R game running, because I was writing it for my trainer . You should change process name and addresses if you know how to do that. Otherwise, feel free to copy any part of code and use it.