Skip to content

Instantly share code, notes, and snippets.

View robert-werner's full-sized avatar

Leonid robert-werner

  • Saransk, Russia
View GitHub Profile
#!/bin/bash
apt-get update
apt-get install -y ca-certificates curl
install -m 0755 -d /etc/apt/keyrings
curl -fsSL https://download.docker.com/linux/ubuntu/gpg -o /etc/apt/keyrings/docker.asc
chmod a+r /etc/apt/keyrings/docker.asc
# Add the repository to Apt sources:
echo \
@robert-werner
robert-werner / wireguard-access-fix.ps1
Last active March 30, 2025 10:43
Wireguard "Access Denied" fix on Windows 10+
$rule = New-Object System.Security.AccessControl.RegistryAccessRule(
"NT AUTHORITY\NETWORK SERVICE", # IdentityReference
[System.Security.AccessControl.RegistryRights]::FullControl, # RegistryRights
[System.Security.AccessControl.InheritanceFlags]::ContainerInherit, # InheritanceFlags
[System.Security.AccessControl.PropagationFlags]::None, # PropagationFlags
[System.Security.AccessControl.AccessControlType]::Allow # AccessControlType
)
$registry_keys = "Dhcp", "Tcpip", "Tcpip6", "TCPIPTUNNEL", "TCPIP6TUNNEL"
$registry_folder = "HKLM:\SYSTEM\CurrentControlSet\Services\{registry_key}"
@robert-werner
robert-werner / network_service_acl.xml
Created January 20, 2025 21:02
The PowerShell-exported (NT AUTHORITY\NETWORK SERVICE) ACL-right with FullControl permission.
<Objs Version="1.1.0.1" xmlns="http://schemas.microsoft.com/powershell/2004/04">
<Obj RefId="0">
<TN RefId="0">
<T>System.Security.AccessControl.RegistryAccessRule</T>
<T>System.Security.AccessControl.AccessRule</T>
<T>System.Security.AccessControl.AuthorizationRule</T>
<T>System.Object</T>
</TN>
<ToString>System.Security.AccessControl.RegistryAccessRule</ToString>
<Props>
['AdjustToContents', 'AdjustToContentsOnFirstShow', 'AdjustToMinimumContentsLength', 'AdjustToMinimumContentsLengthWithIcon', 'DrawChildren', 'DrawWindowBackground', 'IgnoreMask', 'InsertAfterCurrent', 'InsertAlphabetically', 'InsertAtBottom', 'InsertAtCurrent', 'InsertAtTop', 'InsertBeforeCurrent', 'InsertPolicy', 'NoInsert', 'PaintDeviceMetric', 'PdmDepth', 'PdmDevicePixelRatio', 'PdmDevicePixelRatioScaled', 'PdmDpiX', 'PdmDpiY', 'PdmHeight', 'PdmHeightMM', 'PdmNumColors', 'PdmPhysicalDpiX', 'PdmPhysicalDpiY', 'PdmWidth', 'PdmWidthMM', 'RenderFlag', 'RenderFlags', 'SizeAdjustPolicy', '__class__', '__delattr__', '__dict__', '__dir__', '__doc__', '__eq__', '__format__', '__ge__', '__getattr__', '__getattribute__', '__gt__', '__hash__', '__init__', '__init_subclass__', '__le__', '__len__', '__lt__', '__module__', '__ne__', '__new__', '__reduce__', '__reduce_ex__', '__repr__', '__setattr__', '__sizeof__', '__str__', '__subclasshook__', '__weakref__', 'acceptDrops', 'accessibleDescription', 'accessibleName', 'ac
wget --user=leonid_fr --password=31p0ybfjA -P /root/Desktop/my_tiles/t39wvm https://datapool.asf.alaska.edu/GRD_HD/SB/S1B_IW_GRDH_1SDV_20200604T030134_20200604T030159_021878_02985A_F7DA.zip
wget --user=leonid_fr --password=31p0ybfjA -P /root/Desktop/my_tiles/t39wvm https://datapool.asf.alaska.edu/GRD_HD/SB/S1B_IW_GRDH_1SDV_20200604T030109_20200604T030134_021878_02985A_C0D9.zip
wget --user=leonid_fr --password=31p0ybfjA -P /root/Desktop/my_tiles/t39wvm https://datapool.asf.alaska.edu/GRD_HD/SB/S1B_IW_GRDH_1SDV_20200602T031759_20200602T031824_021849_029784_CA96.zip
wget --user=leonid_fr --password=31p0ybfjA -P /root/Desktop/my_tiles/t39wvm https://datapool.asf.alaska.edu/GRD_HD/SB/S1B_IW_GRDH_1SDV_20200602T031734_20200602T031759_021849_029784_918C.zip
unzip '/root/Desktop/my_tiles/t39wvm/*.zip' -d /root/Desktop/my_tiles/t39wvm
rm -f /root/Desktop/my_tiles/t39wvm/*.zip
wget --user=leonid_fr --password=31p0ybfjA -P /root/Desktop/my_tiles/t40vck https://datapool.asf.alaska.edu/GRD_HD/SB/S1B_IW_GRDH_1SDV_20200712T0
@robert-werner
robert-werner / install_esa_snap.sh
Last active May 7, 2021 17:27
Installs ESA SNAP
#!/bin/sh
# https://senbox.atlassian.net/wiki/spaces/SNAP/pages/30539778/Install+SNAP+on+the+command+line
# https://senbox.atlassian.net/wiki/spaces/SNAP/pages/30539785/Update+SNAP+from+the+command+line
# SNAP latest Version: http://step.esa.int/main/download/snap-download/
./diskspace_probe.sh "`basename $0`" begin
SNAPVER=8
# avoid NullPointer crash during S-1 processing
java_max_mem=10G
JAVA_HOME=$(readlink -f /usr/bin/java | sed "s:bin/java::")
@robert-werner
robert-werner / fsm2keys.cs
Created May 22, 2019 08:10
Labs and FSM vars to Honeti keys
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.IO;
using System.Text.RegularExpressions;
namespace ConsoleApp1
{