Skip to content

Instantly share code, notes, and snippets.

@z2z
z2z / testwe-vbox.bat
Last active November 14, 2022 09:59 — forked from keyboard-slayer/testwe-vbox.bat
Bypass for TestWE
@echo off
REM https://docs.oracle.com/en/virtualization/virtualbox/6.0/admin/changedmi.html
REM Change here if the VM name is different
SET /P VMname = Name of the VM:
REM If you want to play with values its here!
SET SYSven=Dell
SET SYSprod=Optiplex
SET SYSdate="01/01/2018"
SET vBox="%VBOX_MSI_INSTALL_PATH%VBoxManage.exe"
@z2z
z2z / mxq.md
Created November 10, 2022 13:57 — forked from probonopd/mxq.md

Linux on MXQ (PCB: S805Q_V2.0) m8b_m201_v1@23a35625

Seems to be also known as the HD18Q "black box". https://www.ebay.de/itm/153205410117 ("NEU MXQ S805 Smart 1GB+ 8GB Smart TV Box Android 4.4 Quad Core 1.5 G WIFI", seller "SILVESTRAS RUNTA Network Tech Co. Ltd"), EUR 14,99

I can boot with meson8b_m201d.dtb and wired Ethernet works.

U-boot thinks it is a 512 MB device. Linux does, too. The SDK used seems to be named "s805_0701_512M":

root@vegas805:~# strings /mnt/lib/hw/camera.amlogic.so | grep home/
@z2z
z2z / s905x2_backup.bat
Created November 7, 2022 19:08
s905x2 amlogic backup 4gb nand
# https://github.com/althafvly/aml-flash-tool
update mread store bootloader normal 0x000000400000 bb20022/bootloader.img
update mread store reserved normal 0x000004000000 bb20022/reserved.img
update mread store cache normal 0x000046000000 bb20022/cache.img
update mread store env normal 0x000000800000 bb20022/env.img
update mread store logo normal 0x000000800000 bb20022/logo.img
update mread store recovery normal 0x000001800000 bb20022/recovery.img
update mread store misc normal 0x000000800000 bb20022/misc.img
update mread store dtbo normal 0x000000800000 bb20022/dtbo.img
@z2z
z2z / imagewall.json
Created March 22, 2021 03:50
imagewall
{
"info": {
"index": 0,
"photos": [
{
"engineInfo": {
"rawUrl": "https://i.picsum.photos/id/1012/3973/2639.jpg?hmac=s2eybz51lnKy2ZHkE2wsgc6S81fVD1W2NKYOSh8bzDc"
},
"thumbnail": "Bette Flores"
},
@z2z
z2z / nginx.service
Created October 27, 2020 15:01 — forked from bes1002t/nginx.service
Start Nginx as non root user with systemd
# Stop dance for nginx
# =======================
#
# ExecStop sends SIGSTOP (graceful stop) to the nginx process.
# If, after 5s (--retry QUIT/5) nginx is still running, systemd takes control
# and sends SIGTERM (fast shutdown) to the main process.
# After another 5s (TimeoutStopSec=5), and if nginx is alive, systemd sends
# SIGKILL to all the remaining processes in the process group (KillMode=mixed).
#
# nginx signals reference doc:
@z2z
z2z / add business date exclude.php
Created July 2, 2020 13:46
business date add exclude holiday php
<?php
# $date must be in YYYY-MM-DD format
# You can pass in either an array of holidays in YYYY-MM-DD format
function addBusinessDays($date,$numDays=1,$holidays='') {
$addDay = 0;
while ($numDays--) {
@z2z
z2z / centos7-hyper-v.ks
Created May 2, 2020 16:00
centos 7 bare minimal - hyper-v
#https://bugs.centos.org/view.php?id=7388
#https://forums.centos.org/viewtopic.php?t=47262
#### Here is my kickstart script ####
text
skipx
install
lang en_US.UTF-8
keyboard us
@z2z
z2z / nfs3_firewall_allow.bat
Created April 11, 2020 19:07
need for speed 3 firewall batch
@echo off
:: BatchGotAdmin
:-------------------------------------
REM --> Check for permissions
>nul 2>&1 "%SYSTEMROOT%\system32\cacls.exe" "%SYSTEMROOT%\system32\config\system"
REM --> If error flag set, we do not have admin.
if '%errorlevel%' NEQ '0' (
echo Requesting administrative privileges...
@z2z
z2z / need for speed 4 high stake.reg
Created April 9, 2020 14:02
need for speed 4 high stake.reg window 10 64bit ((Change the Path))
Windows Registry Editor Version 5.00
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths\NfsHs.exe]
"path"="D:\\G\\nfs4hs_ip\\"
[HKEY_LOCAL_MACHINE\SOFTWARE\WOW6432Node\Electronic Arts\Need For Speed High Stakes]
"InstallPath"="D:\\G\\nfs4hs_ip\\"
"Version"="4.00"
"3D Device Description"="Unknown D3D"
"3D Card"="Unknown D3D"
Source: https://www.cyberciti.biz/tips/linux-unix-bsd-nginx-webserver-security.html
This page collects hints how to improve the security of nginx web servers running on Linux or UNIX-like operating systems.
Default Config Files and Nginx Port
/usr/local/nginx/conf/ or /etc/nginx/– The nginx server configuration directory and /usr/local/nginx/conf/nginx.conf is main configuration file.
/usr/local/nginx/html/ or /var/www/html– The default document location.
/usr/local/nginx/logs/ or /var/log/nginx – The default log file location.
Nginx HTTP default port : TCP 80