Skip to content

Instantly share code, notes, and snippets.

View Ran-Xing's full-sized avatar
💭
I may be slow to respond.

星冉 Ran-Xing

💭
I may be slow to respond.
View GitHub Profile
@lucasmenares
lucasmenares / Disable Device Enrollment Program (DEP) notification on macOS Ventura (Apple Silicon Chips).md
Last active January 24, 2024 21:32
Disable Device Enrollment Program (DEP) notification on macOS Sonoma/Ventura (Apple Silicon Chips)

This worked for me on M1 Pro 2021 with MacOS Ventura, original method was for Big Sur but I changed it using a different type of domain block since the old method doesn't work anymore:

First of all, if you want to trigger the notification you can use this command: sudo profiles show -type enrollment

Now we will start. First block your Mac from reaching the domain iprofiles.apple.com. For this you can use your hosts file like:

echo "0.0.0.0 iprofiles.apple.com" | sudo tee -a /etc/hosts

or blocking them from your firewall.

@1277353463
1277353463 / README.md
Created March 20, 2022 02:58 — forked from oevery/README.md
auto.js 学习强国自动脚本

原项目

原修改者项目

我修改的地方:

  • 添加假装分享,全局变量可自行开关,默认开启。

  • 修改最后一条视频循环收藏分享两次为最后两条视频分别分享收藏。

@Ran-Xing
Ran-Xing / active_response_update.sh
Last active January 15, 2022 08:27
Active Response Update 升级主动响应脚本
#!/usr/bin/env sh
##### INIT #####
set -ex
active_response_path=$(
cd "$(dirname "$0")"
pwd
)
read line
@shaneutt
shaneutt / go-ssh-reverse-tunnel.go
Created October 17, 2021 22:31 — forked from codref/go-ssh-reverse-tunnel.go
Go SSH reverse tunnel implementation (SSH -R)
/*
Go-Language implementation of an SSH Reverse Tunnel, the equivalent of below SSH command:
ssh -R 8080:127.0.0.1:8080 operatore@146.148.22.123
which opens a tunnel between the two endpoints and permit to exchange information on this direction:
server:8080 -----> client:8080
@z1076
z1076 / post.go
Last active February 26, 2022 14:30
[Golang网络请求 / resty]
//普通POST请求
resp, err := http.Post(
"http://xxxx.com",
"application/x-www-form-urlencoded",
strings.NewReader(bodyStr))
if err != nil {
fmt.Println(err)
}
defer resp.Body.Close()
@crusj
crusj / code.sh
Created July 23, 2019 01:13
解决ubuntu中文乱码
sudo apt-get install fonts-droid-fallback ttf-wqy-zenhei ttf-wqy-microhei fonts-arphic-ukai fonts-arphic-uming
@cilf
cilf / Dockerfile
Last active April 29, 2023 16:44
Adminer MongoDB docker image
FROM adminer:4.7.1
# WATCH OUT WHEN UPGRADING, THE SED BELOW MIGHT STOP WORKING
MAINTAINER marek@cilf.cz
USER root
RUN apk add autoconf gcc g++ make libffi-dev openssl-dev
RUN pecl install mongodb
RUN echo "extension=mongodb.so" > /usr/local/etc/php/conf.d/docker-php-ext-mongodb.ini
@shaneutt
shaneutt / LICENSE
Last active May 6, 2024 19:40
Golang: Demonstrate creating a CA Certificate, and Creating and Signing Certs with the CA
This is free and unencumbered software released into the public domain.
Anyone is free to copy, modify, publish, use, compile, sell, or
distribute this software, either in source code form or as a compiled
binary, for any purpose, commercial or non-commercial, and by any
means.
In jurisdictions that recognize copyright laws, the author or authors
of this software dedicate any and all copyright interest in the
software to the public domain. We make this dedication for the benefit
@dmrub
dmrub / Dockerfile
Last active April 12, 2023 05:47
Dockerfile piece for installing su-exec in debian/ubuntu container
# Install latest su-exec
RUN set -ex; \
\
curl -o /usr/local/bin/su-exec.c https://raw.githubusercontent.com/ncopa/su-exec/master/su-exec.c; \
\
fetch_deps='gcc libc-dev'; \
apt-get update; \
apt-get install -y --no-install-recommends $fetch_deps; \
rm -rf /var/lib/apt/lists/*; \
gcc -Wall \

Disable Device Enrollment Notification on Mac.md

Restart the Mac in Recovery Mode by holding Comment-R during restart

Open Terminal in the recovery screen and type

csrutil disable