This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
on rooted devices we have to install burp certificate as SYSTEM like this: | |
1. Export burp certificate and convert it to pem | |
a. openssl x509 -inform DER -in cacert.der -out cacert.pem | |
2. output the subject_hash_old and rename the file: | |
a. openssl x509 -inform PEM -subject_hash_old -in cacert.pem |head -1 | |
b. mv cacert.pem <hash>.0 | |
3. Copy the certificate to the device | |
a. adb push <hash>.0 /sdcard/ | |
b. Adb shell |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
## help : Show this help. | |
help: Makefile | |
@printf "Usage: make [target] [VARIABLE=value]\nTargets:\n" | |
@sed -n 's/^## //p' $< | awk 'BEGIN {FS = ":"}; { if(NF>1 && $$2!="") printf " \033[36m%-25s\033[0m %s\n", $$1, $$2 ; else printf "%40s\n", $$1};' | |
@printf "Variables:\n" | |
@grep -E "^[A-Za-z0-9_]*\?=" $< | awk 'BEGIN {FS = "\\?="}; { printf " \033[36m%-25s\033[0m Default values: %s\n", $$1, $$2}' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
server { | |
server_name example.com; | |
listen 443 ssl; | |
ssl_certificate /opt/lego/certificates/example.com.crt; | |
ssl_certificate_key /opt/lego/certificates/example.com.key; | |
access_log /var/log/nginx/sites/example.com.log; | |
location / { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package tplink | |
import ( | |
"git.4z.ee/gleox/tplink/tplink/rsa" | |
) | |
const ( | |
modulus = "D1E79FF135D14E342D76185C23024E6DEAD4D6EC2C317A526C811E83538EA4E5ED8E1B0EEE5CE26E3C1B6A5F1FE11FA804F28B7E8821CA90AFA5B2F300DF99FDA27C9D2131E031EA11463C47944C05005EF4C1CE932D7F4A87C7563581D9F27F0C305023FCE94997EC7D790696E784357ED803A610EBB71B12A8BE5936429BFD" | |
exponent = "010001" | |
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
namespace FipsTest | |
{ | |
public static class Hex | |
{ | |
public const string HexDigits = "0123456789abcdef"; | |
private static char[] _lowerDigits; | |
private static char[] _upperDigits; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.IO; | |
using System.Text; | |
using System.Threading; | |
namespace Utils | |
{ | |
public class DotEnvHelper | |
{ | |
private static int _initialized; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="UTF-8"?> | |
<configuration> | |
<system.webServer> | |
<rewrite> | |
<rules> | |
<rule name="Reverse Proxy to acme" stopProcessing="true"> | |
<match url="(.*)"/> | |
<action type="Rewrite" url="http://localhost:8000/{R:1}"/> | |
</rule> | |
</rules> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="UTF-8"?> | |
<configuration> | |
<system.webServer> | |
<staticContent> | |
<mimeMap fileExtension=".*" mimeType="text/plain" /> | |
</staticContent> | |
</system.webServer> | |
</configuration> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
// see: https://stackoverflow.com/questions/5421972/how-to-find-the-3rd-friday-in-a-month-with-c | |
namespace Demo | |
{ | |
public class ScheduleTimeService | |
{ | |
/// <summary> | |
/// How to find the third Wednesday of the month of the specific time | |
/// </summary> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="UTF-8"?> | |
<configuration> | |
<system.webServer> | |
<rewrite> | |
<rules> | |
<rule name="pages" enabled="true" stopProcessing="true"> | |
<match url="(.*)" /> | |
<action type="Rewrite" url="/" /> | |
<conditions logicalGrouping="MatchAll"> | |
<add input="{REQUEST_URI}" matchType="Pattern" pattern="/(api|static)(.*)$" ignoreCase="true" negate="true" /> |
NewerOlder