Skip to content

Instantly share code, notes, and snippets.

Avatar
🚀
Focusing

Faraz Fallahi fffaraz

🚀
Focusing
View GitHub Profile
@markerikson
markerikson / job-search-questions.md
Last active May 9, 2022
Assorted questions to ask companies in interviews
View job-search-questions.md

Questions

Company

  • company location / remote?
  • what project management method?
  • good and bad company culture?
  • performance reviews?
  • what's the path to profitability?
@Neo23x0
Neo23x0 / log4j_rce_detection.md
Last active Jul 14, 2022
Log4j RCE CVE-2021-44228 Exploitation Detection
View log4j_rce_detection.md

log4j RCE Exploitation Detection

You can use these commands and rules to search for exploitation attempts against log4j RCE vulnerability CVE-2021-44228

Grep / Zgrep

This command searches for exploitation attempts in uncompressed files in folder /var/log and all sub folders

sudo egrep -I -i -r '\$(\{|%7B)jndi:(ldap[s]?|rmi|dns|nis|iiop|corba|nds|http):/[^\n]+' /var/log
@abraithwaite
abraithwaite / chill-zoom.sh
Last active Mar 6, 2022
Zoom in Systemd Cgroups on Linux. Change the max allocations to fit your workstation.
View chill-zoom.sh
#!/usr/bin/bash -xe
cat <<EOF > "${HOME}/.config/systemd/user/zoom.slice"
[Slice]
AllowedCPUs=0-4
MemoryHigh=6G
EOF
cat /usr/share/applications/Zoom.desktop | sed -E 's#^(Exec=).*$#Exec=/usr/bin/systemd-run --user --slice=zoom.slice /opt/zoom/ZoomLauncher#' > "${HOME}/.local/share/applications/Zoom.desktop"
View company.py
lst = [
{"current_time":1618861512,"success":True,"data":[{"id":590,"company":{"name":"افسران جنگ نرم","name_en":"Afsaran","company_slug":"afsaran","logo":"/company/afsaran/9f7d4c70-403a-11e9-ae0e-273fe94d6d59.png"},"job":{"job_slug":"full-stack","name":"Full Stack"},"title":"شرکت افسران جنگ نرم درخواست رسمی خود را مبنی بر عدم به اشتراک گذاری این اطلاعات بر روی پلتفرم جابگای ابلاغ کرده و به این منظور جابگای مجبور به حذف این اطلاعات میباشد.","description":"شرکت افسران جنگ نرم درخواست رسمی خود را مبنی بر عدم به اشتراک گذاری این اطلاعات بر روی پلتفرم جابگای ابلاغ کرده و به این منظور جابگای مجبور به حذف این اطلاعات میباشد.","vote_count":0,"down_vote_count":2,"vote_state":"NONE","view_count":61,"over_all_rate":0,"created":"2020-06-10 18:37","my_review":False,"state":"FULL","approved":True,"has_legal_issue":True}],"message":None,"total":1,"show_type":"TOAST","index":0},
{"current_time":1618861554,"success":True,"data":[{"id":60,"company":{"name":"آپاسای داده سیستم","name_en":"Apasai Dade System","company_sl
@prologic
prologic / LearnGoIn5mins.md
Last active Aug 12, 2022
Learn Go in ~5mins
View LearnGoIn5mins.md
@moaminsharifi
moaminsharifi / spotify_ad_blocker.md
Created Oct 16, 2020
#spotify ad blocker /etc/hosts
View spotify_ad_blocker.md

#spotify ad blocker

edit /etc/hosts on linux

c:\windows\system32\drivers\etc\hosts

more in How to Edit Your Hosts File on Windows, Mac, or Linux

127.0.0.1 media-match.com
127.0.0.1 adclick.g.doublecklick.net
127.0.0.1 www.googleadservices.com
127.0.0.1 open.spotify.com
127.0.0.1 pagead2.googlesyndication.com
@IanColdwater
IanColdwater / twittermute.txt
Last active Aug 12, 2022
Here are some terms to mute on Twitter to clean your timeline up a bit.
View twittermute.txt
Mute these words in your settings here: https://twitter.com/settings/muted_keywords
ActivityTweet
generic_activity_highlights
generic_activity_momentsbreaking
RankedOrganicTweet
suggest_activity
suggest_activity_feed
suggest_activity_highlights
suggest_activity_tweet
@charlesroper
charlesroper / gist:f2da6152d6789fa6f25e9d194a42b889
Last active Aug 14, 2022
How to setup a practically free CDN
View gist:f2da6152d6789fa6f25e9d194a42b889

How to setup a practically free CDN

I've been using [Backblaze][bbz] for a while now as my online backup service. I have used a few others in the past. None were particularly satisfactory until Backblaze came along.

It was - still is - keenly priced at a flat $5 (£4) per month for unlimited backup (I've currently got just under half a terabyte backed-up). It has a fast, reliable client. The company itself is [transparent about their operations][trans] and [generous with their knowledge sharing][blog]. To me, this says they understand their customers well. I've never had reliability problems and everything about the outfit exudes a sense of simple, quick, solid quality. The service has even saved the day on a couple of occasions where I've lost files.

Safe to say, I'm a happy customer. If you're not already using Backblaze, [I highly recommend you do][recommend].

Taking on the big boys with B2

@shafik
shafik / WhatIsStrictAliasingAndWhyDoWeCare.md
Last active Aug 14, 2022
What is Strict Aliasing and Why do we Care?
View WhatIsStrictAliasingAndWhyDoWeCare.md

What is the Strict Aliasing Rule and Why do we care?

(OR Type Punning, Undefined Behavior and Alignment, Oh My!)

What is strict aliasing? First we will describe what is aliasing and then we can learn what being strict about it means.

In C and C++ aliasing has to do with what expression types we are allowed to access stored values through. In both C and C++ the standard specifies which expression types are allowed to alias which types. The compiler and optimizer are allowed to assume we follow the aliasing rules strictly, hence the term strict aliasing rule. If we attempt to access a value using a type not allowed it is classified as undefined behavior(UB). Once we have undefined behavior all bets are off, the results of our program are no longer reliable.

Unfortunately with strict aliasing violations, we will often obtain the results we expect, leaving the possibility the a future version of a compiler with a new optimization will break code we th

@steven2358
steven2358 / ffmpeg.md
Last active Aug 12, 2022
FFmpeg cheat sheet
View ffmpeg.md