var topics = [ { "title":"To Research", "draft":"false", "date": "2018-04-13 15:10:33 -0600 -0600", "link": "https://wiki.punkcoder.com/topic/to-research/", "content": " To Research Federal Cybersecurity Training Threat Modeling Cookbook Metatwin Powershell Empire FireEye Free Tools routersecurity.org Lookup Powershell Query on AD : setspn -T forrest -q */* LinkInfo.dll js-search Nirsoft airba.sh Threat Dragon Invoke-PSImage - BSides Nashville 2018 Invoke-WCMDump - BSides Nashville 2018 Invoke-UserSimulator - BSides Nashville 2018 Icebreaker - Autopwn - BSides Nashville 2018 DeathStar - Autopwn - BSides Nashville 2018 Bloodhound - BSides Nashville 2018 Killcord - Censorship Resistant Killswitch azucar - Azure pentest tool Unconventional Cryptography Gauntlt Automated Security Testing Framework - Applications Security Weekly #17 WebSecurity Dojo Dokku 12 Factor Mesos Marathon UI for Mesos Azure Sphere Seven Properties of Highly Secure Devices Security Onion Bro Network Security Monitor Elsa - Enterprise Log Search and Archive Security Auditing for npm wireguard vpn Gitrob Jupyter SSH-Auditor Awesome .NET Core Assume the Worst: AWS Role Enumeration Open Source Threat Feeds Botnet Repo Wasabi WASM Analyzer Bypassing CSP using polyglot JPEGs Watch your hack Windows Privledge Escalation Guide Vulnerable Docker VM Chall Frida Native Javascript RE tool procdump32 and powerdump Mitre Attack Framework Jenking Pentesting Pentest Execution Standard .NET DLR Offensive DLR Toolkit Silent Trinity C2 Server recon bash scripts free for developers Getting Started with Att\u0026amp;ck joyent tritin Kubernetes Goat Free DFIR Training Standards and Process NIST Privacy Framework Interesting Software Beaker Browser P2P internet Threat Research Feeds Tweets from @cvenew Tweets from @cveannounce Conference Feeds Infosec Events Items from DEFCON Cell tower in a box Signal-cli SMS IRC The quantum resistant ledger Blocking Resistant Tor recon-ng Online capture tool for recon Buscador OS https://github.com/calebmadrigal/trackerjacker OWASP Amass Items from DC720 Censys Advanced Reconisence Framework Open Source Intellegence Sparta Tool fierce.pl subdomains-top1mill-20000.txt Google Custom Search spiderfoot Research ThingMagic Kubernetes Security Bust-a-kube Kube-goat Kubernetes Security Kubernetes Security Best-Practices Kubernetes GOAT " }, { "title":"Reading Room", "draft":"false", "date": "2018-04-16 14:44:42 -0600 -0600", "link": "https://wiki.punkcoder.com/topic/reading-room/", "content": " Reading Room Socially Important NeverAgain.tech Interesting Links Dark Reading Room Hacker Factor Hacker News irongeek the grugq @ medium Sam Bowne\u0026#39;s Classes Site Schneier on Security Podcasts Hacker Daily " }, { "title":"Recommended Learning", "draft":"false", "date": "2018-04-13 15:04:14 -0600 -0600", "link": "https://wiki.punkcoder.com/topic/recommended-learning/", "content": " Recommended Learning Reading Materials Useful Repositories berzerk0/Probable-Wordlists swisskyrepo/PayloadsAllTheThings carpedm20/awesome-hacking#readme Online Documentation Docker Security Best Practices Microsoft Guide to Threat Modeling Microsoft Patterns and Practices: Improving Web Application Security: Threats and Countermeasures Microsoft Security Engineering: Secure Software Developement Lifecycle OWASP Guide to Cryptography OWASP Testing Guide V4 OWASP Threat Modeling Guide Treeware Applied Cryptography: Protocols, Algorithms and Source Code in C 20th Anniversary Edition Writing Secure Code, Second Edition (Developer Best Practices) Pleasurable Reading [amazon] Beyond Fear by Bruce Schneier [amazon] The Code Book: The Science of Secrecy from Ancient Egypt to Quantum Cryptography by Simon Singh Podcasts .NET Rocks Pauls Security Weekly Application Security Weekly Fireside with LEI Hacked Malicious Life 2600 - Off the Hook 2600 - Off the Wall The Social Engineer Podcast DevSecOps Podcast Down the Security Rabbithole Podcast Welcome to Nightvale Training Training Sites Cybrary [pluralsight] Troy Hunts Catalog CTF Feild Guide Pentesting Labs Jim Kurose - Wireshark Labs Sam Browne Sam Browne has been a fantastic resource in the community and usually if I am diving into a topic he is one of the first places that I go to look for intro material into the subject. I have had to opportunity now to take two separate classes with him at DEFCON and his contribution to the community and open education is truly something to be in awe of.\n Old Classes Index CNIT 126: Malware Analysis CNIT 128: Hacking Mobile Devices Interesting Youtube Tess Schrodinger - Cryptography Codes and Secret Writing AppSec Village - Youtube Modern Problem Solving Tutorials Kontra Labs Excess XSS Chall These are challenge sites that are designed to sharpen your skills and present you with problems and help you to develop the skills to address those problems.\n WeChall - A Collection of Chall Sites Hack the Box Hack this Site Hack This Game of Hacks - Spot the Vuln in Code Damn Vulnerable iOS App BwApps Vulnerable Web Application Hellbound Hackers Cydefe CTF CTF Listing VulnHub - Community Submitted Vulnerable VMs Pentest it labs MicroCorruption Embedded Security CTF OverTheWire CTF Smash the Stack Wargames Cryptopals " }, { "title":"Penetration Testing", "draft":"false", "date": "2018-04-13 15:00:22 -0600 -0600", "link": "https://wiki.punkcoder.com/topic/pentesting/", "content": " Penetration Testing IoT / Mobile Application Testing Fastboot Kali Tools Nikto Other Tools Mobile Security Framework Payload all the things Dirty Tricks WordPad Code Execution Pentesting Notes pentesting-apache pentesting-memcached pentesting-nmap " }, { "title":"Life", "draft":"false", "date": "2018-04-16 11:05:41 -0600 -0600", "link": "https://wiki.punkcoder.com/topic/life/", "content": " Life Funny " }, { "title":"Open Source Intelligence", "draft":"false", "date": "2018-04-16 11:05:05 -0600 -0600", "link": "https://wiki.punkcoder.com/topic/osint/", "content": " Open Source Intelligence DNS Let\u0026rsquo;s Encrypt Certificate Transparency (CT) Logs " }, { "title":"Security", "draft":"false", "date": "2018-04-16 11:05:05 -0600 -0600", "link": "https://wiki.punkcoder.com/topic/security/", "content": " Security Android Forensics selinux Operational Security Security Training Pentesting Security Tools Social Engineering System Compromise To Research Stupid Linux Tricks OSInt Links https://github.com/drduh/YubiKey-Guide " }, { "title":"Programming", "draft":"false", "date": "2018-04-16 11:04:10 -0600 -0600", "link": "https://wiki.punkcoder.com/topic/programming/", "content": " Programming Notes and Snippets C Sharp Snippets Docker Docker Compose gdb Hugo Kubernetes Stupid Git Tricks Stupid Linux Tricks Stupid SQL Tricks Tools Training edX Courses Microsoft Virtual Academy Visual Studio Code Extensions makedownlint PlantUml Rewrap Spell Right TypeScript Hero " }, { "title":"Funny", "draft":"false", "date": "2018-04-13 14:51:41 -0600 -0600", "link": "https://wiki.punkcoder.com/topic/funny/", "content": " Funny CyberSquirl1 - This map lists all unclassified Cyber Squirrel Operations that have been released to the public that we have been able to confirm. There are many more executed ops than displayed on this map however, those ops remain classified. IP By Pigeon - In computer networking, IP over Avian Carriers (IPoAC) is a humorously intended proposal to carry Internet Protocol (IP) traffic by birds such as homing pigeons. RFC2324 - I\u0026#39;m a Teapot - There is coffee all over the world. Increasingly, in a world in which computing is ubiquitous, the computists want to make coffee. The UX on this Small Child is Terrible Self Explanatory. " }, { "title":"News of Note", "draft":"false", "date": "2019-07-29 09:04:14 -0600 -0600", "link": "https://wiki.punkcoder.com/topic/news/", "content": " News This is a list of news stories that I want to retain for conversations at a later date.\n [2022-08-24] 8,000,000 iOS Vulnerability [2022-04-11] AWS Lambda sees its first malware attack with Denonia, and we don’t know how it got there [2019-12-04] Two malicious Python libraries caught stealing SSH and GPG keys [2019-07-29] Malicious code in the purescript npm installer [2019-04-25] 19 Telangana students commit suicide in a week after \u0026lsquo;goof-ups\u0026rsquo; in intermediate exam results; parents blame software firm [2019-04-23] Supply chain hackers snuck malware into videogames [2019-04-14] The Russians are screwing with the GPS system to send bogus navigation data to thousands of ships [2018-12-03] #DarkUI iOS App Scam Fitness tracking touch id [2018-12-03] #RealIssue How can we stop being cyber idiots? [2018-08-23] California passes nations\u0026rsquo;s fist IoT security bill - too little too late Important Tweets VBullitin hack after 8-min https://twitter.com/punkcoder/status/1176967234314493959 " }, { "title":"Tools", "draft":"false", "date": "2018-07-06 12:01:34 -0600 -0600", "link": "https://wiki.punkcoder.com/topic/tools/", "content": " Tools ASCII ASCIIFlow Block Chain Codius Hosting Platform Rest Insomnia Rest Client (Postman Alternative) " }, { "title":"wordPad code execution", "draft":"false", "date": "2018-06-04 10:35:25 -0600 -0600", "link": "https://wiki.punkcoder.com/topic/wordpad-code-execution/", "content": "To move a file into a remote system you only have Remote Desktop access to:\n launch wordpad locally paste exe - copy it into clipboard open wordpad remotely paste file into remote wordpad right click \u0026gt; activate - file will launch Source " }, { "title":"Stupid Sql Tricks", "draft":"false", "date": "2018-05-15 14:33:44 -0600 -0600", "link": "https://wiki.punkcoder.com/topic/stupid-sql-tricks/", "content": " Stupid SQL Tricks Search for all instances of a column name:\nSELECT OBJECT_NAME(OBJECT_ID), definition\rFROM sys.sql_modules\rWHERE definition LIKE \u0026#39;%\u0026#39; + \u0026#39;ColumnName\u0026#39; + \u0026#39;%\u0026#39;\rGO " }, { "title":"Stupid Linux Tricks", "draft":"false", "date": "2018-05-10 13:13:06 -0600 -0600", "link": "https://wiki.punkcoder.com/topic/stupid-linux-tricks/", "content": " Stupid Linux Tricks Fun Stuff Format JSON from the command line with: jq Lock Down Account adduser \u0026lt;user\u0026gt; id \u0026lt;user\u0026gt; # For sudo permissions for your new admin user, use the following command. echo '\u0026lt;user\u0026gt; ALL=(ALL) ALL' \u0026gt;\u0026gt; /etc/sudoers vi /etc/ssh/sshd_config # Change this line: #PermitRootLogin yes # Edit to this: PermitRootLogin no # Ensure that you are logged into the box with another shell before restarting sshd to avoid locking yourself out of the server. Use Private Key for login Run the following command on the machine that you will be sshing from.\nssh-keygen -t rsa -b 2048 -v ssh-copy-id -i ~/hetzner.pub root@12.34.56.78 Add a user to the Sudoers Group sudo usermod -aG sudo \u0026lt;user\u0026gt; " }, { "title":"Docker Compose", "draft":"false", "date": "2018-05-10 13:01:59 -0600 -0600", "link": "https://wiki.punkcoder.com/topic/docker-compose/", "content": " Docker Compose Also See Docker Basic Commands Get Help:\ndocker-compose up --help\nStart A Compose Script:\n-d runs it in the background\ndocker-compose up -d\nGet a list of all of the processes running:\ndocker-compose ps\nShutdown A Compose Script:\ndocker-compose down\n" }, { "title":"Conference Feeds", "draft":"false", "date": "2018-04-23 11:07:38 -0600 -0600", "link": "https://wiki.punkcoder.com/topic/conference-feeds/", "content": " Security Conferences BSides Boulder BSidesBoulder 2021 BSidesBoulder 2020 BlackHat BlackHat (defcon for suits) BlackHat 2018 BlackHat 2017 BlackHat 2016 DEFCON DEF CON DEF CON 29 Main DEF CON 29 - AppSec Village DEFCON 28 Main DEF CON 28 - AppSec Village DEF CON 27 DEF CON China 1 DEF CON 26 DEF CON 25 DEF CON 24 OURSA OURSA OURSA 2018 Amegala Amegala : Prarie.Code(), Nebraska.Code(), Indy.Code(), Detroit.Code() " }, { "title":"Threat Modeling", "draft":"false", "date": "2018-04-23 11:07:38 -0600 -0600", "link": "https://wiki.punkcoder.com/topic/threat_modeling/", "content": " Resources for Threat Modeling NIST 800-154 Guide to Data-Centric System Threat Modeling Cyber Threat Modeling: Survey, Assessment, and Representative Framework Threat Modeling: Designing for Security The Threat Modeling Manifesto Tools for Threat Modeling Microsoft Threat Modeling Tool Threat Dragon PyTM Blogs for Threat Modeling Adam Shostacks Blog Videos Worlds shortest threat modeling videos " }, { "title":"Hugo", "draft":"false", "date": "2018-04-16 14:38:09 -0600 -0600", "link": "https://wiki.punkcoder.com/topic/hugo/", "content": " Hugo (Static Site Generator) Hugo is a good tool for working with sites that need to be static.\n" }, { "title":"Stupid Git Tricks", "draft":"false", "date": "2018-04-16 08:58:29 -0600 -0600", "link": "https://wiki.punkcoder.com/topic/stupid-git-tricks/", "content": " Stupid Git Tricks Reverting files in a commit Sometimes there is a need to just revert certain files in a commit to do this the fastest way to accomplish this is using the checkout command.\ngit checkout \u0026lt;commitid\u0026gt; -- file1/to/restore\nGet the contents of all of the changes output to a file This can be helpful when searching through the entire history looking for data buried in checkins that were removed. Very helpful when looking for secrets or api keys that were removed from code.\ngit log -p \u0026gt; \u0026lt;filename\u0026gt;\n" }, { "title":"Security Tools", "draft":"false", "date": "2018-04-13 15:29:45 -0600 -0600", "link": "https://wiki.punkcoder.com/topic/security-tools/", "content": " Security Tool Sites Hack4NET hax4All " }, { "title":"System Compromise", "draft":"false", "date": "2018-04-13 15:23:40 -0600 -0600", "link": "https://wiki.punkcoder.com/topic/system-compromise/", "content": "home\nSystem CompromiseUnusual Log\u0026nbsp;Entries “Event log service was stopped.” “Windows File Protection is not active on this system.” “The protected System file file name was not restored to its original, valid version because of the Windows File Protection…” “The MS Telnet Service has started successfully.” Look for a large number of failed logon attempts or locked out accounts. Access to Event\u0026nbsp;Viewer C:\u0026gt; eventvwr.msc Using the command prompt: C:\u0026gt; eventquery.vbs | more Or, to focus on a particular event log: C:\u0026gt; eventquery.vbs /L security Unusual Process and\u0026nbsp;Services: Look for unusual/unexpected processes, and focus on processes with User Name “SYSTEM” or “Administrator” (or users in the Administrators’ group). You need to be familiar with normal processes and services and search for deviations. Using the GUI, run Task Manager: C:\u0026gt; taskmgr.exe Using the command prompt: C:\u0026gt; tasklist C:\u0026gt; wmic process list full Also look for unusual services. Using the GUI: C:\u0026gt; services.msc Using the command prompt: C:\u0026gt; net start C:\u0026gt; sc query For a list of services associated with each process: C:\u0026gt; tasklist /svc Unusual Files and Registry\u0026nbsp;Keys Check file space usage to look for sudden major decreases in free space, using the GUI (right-click on a partition), or type: C:\u0026gt; dir c: Look for unusually big files: Start–\u0026gt; Search–\u0026gt;For Files of Folders… Search Options–\u0026gt;Size–\u0026gt;At Least 10000KB Look for strange programs referred to in registry keys associated with system start up: HKLMSoftwareMicrosoftWindowsCurrentVersionRun HKLMSoftwareMicrosoftWindowsCurrentVersionRunonce HKLMSoftwareMicrosoftWindowsCurrentVersionRunonceEx Note that you should also check the HKCU counterparts (replace HKLM with HKCU above). Using the GUI: C:\u0026gt; regedit Using the command prompt: C:\u0026gt; reg query \u0026lt;reg key\u0026gt; Penetration Testing Cheat Sheet for Unusual Network\u0026nbsp;Usage Look at file shares, and make sure each has a defined business purpose: C:\u0026gt; net view \\127.0.0.1 Look at who has an open session with the machine: C:\u0026gt; net session Look at which sessions this machine has opened with other systems: C:\u0026gt; net use Look at NetBIOS over TCP/IP activity: C:\u0026gt; nbtstat –S Look for unusual listening TCP and UDP ports: C:\u0026gt; netstat –na For continuously updated and scrolling output of this command every 5 seconds: C:\u0026gt; netstat –na 5 The –o flag shows the owning process id: C:\u0026gt; netstat –nao 5 The –b flag shows the executable name and the DLLs loaded for the network connection. C:\u0026gt; netstat –naob 5 Note that the –b flag uses excessive CPU resources. Again, you need to understand normal port usage for the system and look for deviations. Also, check Windows Firewall configuration: C:\u0026gt; netsh firewall show config Unusual Scheduled\u0026nbsp;Tasks Look for unusually scheduled tasks, especially those that run as a user in the Administrators group, as SYSTEM, or with a blank user name. Using the GUI, run Task Scheduler: Start–\u0026gt;Programs–\u0026gt;Accessories–\u0026gt;System Tools–\u0026gt;Scheduled Tasks Using the command prompt: C:\u0026gt; schtasks Check other autostart items as well for unexpected entries, remembering to check user autostart directories and registry keys. Using the GUI, run msconfig and look at the Startup tab: Start –\u0026gt; Run, msconfig.exe Using the command prompt: C:\u0026gt; wmic startup list full Unusual Accounts Look for new, unexpected accounts in the Administrators group: C:\u0026gt; lusrmgr.msc Click on Groups, Double Click on Administrators, then check members of this group. This can also be done at the command prompt: C:\u0026gt; net user C:\u0026gt; net localgroup administrators Other Unusual\u0026nbsp;Items Look for unusually sluggish performance and a single unusual process hogging the CPU: Task Manager –\u0026gt; Process and Performance tabs Look for unusual system crashes, beyond the normal level for the given system. On a periodic basis (daily, weekly, or each time you logon to a system you manage,) run through these quick steps to look for anomalous behavior that might be caused by a computer intrusion. Each of these commands runs locally on a system. Source " }, { "title":"Social Engineering", "draft":"false", "date": "2018-04-13 15:20:06 -0600 -0600", "link": "https://wiki.punkcoder.com/topic/social-engineering/", "content": " Social Engineering Check Phone Caller " }, { "title":"Powershell Empire", "draft":"false", "date": "2018-04-13 15:16:24 -0600 -0600", "link": "https://wiki.punkcoder.com/topic/powershell-empire/", "content": " Powershell Empire Empire is a pure PowerShell post-exploitation agent built on cryptologically-secure communications and a flexible architecture. Empire implements the ability to run PowerShell agents without needing powershell.exe, rapidly deployable post-exploitation modules ranging from key loggers to Mimikatz, and adaptable communications to evade network detection, all wrapped up in a usability-focused framework.\n Powershell Empire Website From Paul\u0026#39;s Security Weekly More Information Moobix Kerberoasting Black Hills Security - Kerberosting Defending Detecting Kerberoasting Activity " }, { "title":"Metatwin", "draft":"false", "date": "2018-04-13 15:10:44 -0600 -0600", "link": "https://wiki.punkcoder.com/topic/metatwin/", "content": " Metatwin The project is designed as a file resource cloner. Metadata, including digital signature, is extracted from one file and injected into another. Note: Signatures are copied, but no longer valid.\nThis project is based on a technique I’ve used for a few years. This has been updated and modified to include copying digital signatures.\nThanks @subtee for the tweet that encouraged this project to be updated and published !!\nA blog post on this topic can be found at threatexpress.com\n Paul\u0026#39;s Security Weekly GitHub " }, { "title":"Kubernetes", "draft":"false", "date": "2018-04-13 15:06:27 -0600 -0600", "link": "https://wiki.punkcoder.com/topic/kubernetes/", "content": " Kubernetes Gets a list of all of the pods that are currently in the namespace.\nkubectl get pods --all-namespaces\nGetting access to the powershell environment from within the kubernetes cluster.\nkubectl exec -it \u0026lt;podname\u0026gt; -- powershell\nGets all of the information about the status of the pod from within Kubernetes.\nkubectl describe pod \u0026lt;podname\u0026gt;\nKubernetes Cheat Sheet Set Kuberenetes Config:\nexport KUBECONFIG=\u0026lt;path_to_kubecfg\u0026gt;\nMicrok8s Installing brew install ubuntu/microk8s/microk8s microk8s install microk8s status --wait-ready microk8s enable dashboard dns registry istio microk8s kubectl get all --all-namespaces microk8s dashboard-proxy Starting Microk8s: microk8s start\nStopping Microk8s: microk8s stop\nHelpful alias: alias kubectl=\u0026quot;microk8s kubectl\u0026quot; Commands: Gets a list of all of the nodes in the cluster\nmicrok8s kubectl get nodes\nGets the nodes with the wide setting that includes internal and exteranl ip addresses:\nmicrok8s kubectl get nodes -o wide\nkubectl Command for creating a manual deployment on a k8s cluster:\nkubectl create deployment \u0026lt;deployment_name\u0026gt; --image=\u0026lt;docker_image\u0026gt;\nCommand for exposing a port on a deployment:\nkubectl expose deployment \u0026lt;deployment_name\u0026gt; --type=NodePort --port=\u0026lt;port\u0026gt;\nkubectl expose deployment \u0026lt;deployment_name\u0026gt; --type=NodePort --port=\u0026lt;port\u0026gt; --target-port=\u0026lt;internal_port_number\u0026gt;\nCommand for checking the status of a deployment including the port number:\nkubectl get service \u0026lt;deployment_name\u0026gt;\nCommand for deleteing a deployment:\nkubectl delete -n default deployment \u0026lt;deployment_name\u0026gt;\nCommand for deleteing a service:\nkubectl delete -n default service \u0026lt;deployment_name\u0026gt;\nCommand for Getting the deployment\nwatch kubectl get deployment \u0026lt;deployment_name\u0026gt;\nCommand for getting status of the pod:\nkubectl get pod -l app=\u0026lt;deployment_name\u0026gt;\nCommand for getting the description of an issue with a pod:\nkubectl describe pod -l app=\u0026lt;deployment_name\u0026gt;\nConnecting a repository instance to a k8s cluster **Note: the password that is used here is not your password but a toekn that is created from dockerhub -\u0026gt; Security -\u0026gt; Access Tokens\nFor connecting to docker hub:\nkubectl create secret docker-registry regcred --docker-username=\u0026lt;username\u0026gt; --docker-password=\u0026lt;password\u0026gt; --docker-email=\u0026lt;emailaddress\u0026gt;\nWhen connecting to a server other than docker hub:\nkubectl create secret docker-registry regcred --docker-username=\u0026lt;username\u0026gt; --docker-password=\u0026lt;password\u0026gt; --docker-email=\u0026lt;emailaddress\u0026gt; --server=\u0026lt;server\u0026gt;\nList all of the secrets:\nkubectl get secrets\nEditing the Settings of a deployment kubectl edit deployment \u0026lt;deployment_name\u0026gt;\nYou can get a yaml output via:\nkubectl get service \u0026lt;deployment_name\u0026gt; -o yaml\nGetting Log infromation about the status of a pod This will get the logs of the process that is running and will follow the output of the process, -l will get everything associated with the label and \u0026ndash;prefix=true will return the name of the pod as part of the output.\nkubectl logs -f -l app=\u0026lt;deployment_name\u0026gt; --prefix=true\nUpgrade the image of a container The container image label can bee seen in the pod template under the containers:\nkubectl set image deployment/\u0026lt;deployment_name\u0026gt; \u0026lt;kubernetes_container_label\u0026gt;=\u0026lt;repo/image:tag\u0026gt;\nGet a history of all of the changes to a deployment:\nkubectl rollout history deployment \u0026lt;deployment_name\u0026gt;\nThis command will rollback a deployment:\nkubectl rollout undo deployment \u0026lt;deployment_name\u0026gt;\nNamespaces Create a namespace:œ\nkubectl create namespace \u0026lt;namespace_name\u0026gt;\nDelete a namespace and all items running under it:\nkubectl delete namespace \u0026lt;namespace_name\u0026gt;\nApply a yaml file kubectl appy -f \u0026lt;yaml_file\u0026gt;\nSet context kubectl config set-context --current --namespace=\u0026lt;namespace\u0026gt;\n" }, { "title":"C# Snippets", "draft":"false", "date": "2018-04-13 15:04:14 -0600 -0600", "link": "https://wiki.punkcoder.com/topic/c-sharp-snippets/", "content": " C# Snippets " }, { "title":"Docker Commands", "draft":"false", "date": "2018-04-13 15:04:14 -0600 -0600", "link": "https://wiki.punkcoder.com/topic/docker/", "content": " Docker Also See: Docker Compose Docker Basic Commands List All of the Containers:\ndocker container ls -a\nRun Named instance as a daemon\ndocker container run -d --name \u0026lt;containername\u0026gt; \u0026lt;imagename\u0026gt;\nRemove a Container\ndocker container rm \u0026lt;containername\u0026gt;\nPublish a port (specify external port):\ndocker container run -d --name \u0026lt;containername\u0026gt; -p \u0026lt;externalport\u0026gt;:\u0026lt;internalport\u0026gt; \u0026lt;imagename\u0026gt;\nPublish a port (dynamically exposed port):\ndocker container run -d --name \u0026lt;containername\u0026gt; -p \u0026lt;internalport\u0026gt; \u0026lt;imagename\u0026gt;\nPublish a Volume with Local Storage:\ndocker container run -d -v \u0026lt;localpath\u0026gt;:\u0026lt;containerpath\u0026gt; \u0026lt;imagename\u0026gt;\nRunning Docker Run a process that will complete at the end:\ndocker container run --rm \u0026lt;imagename\u0026gt;\nBackup To get a list of all running Items:\ndocker ps\nCreate a backup of the image:\ndocker commit -p \u0026lt;hash\u0026gt; \u0026lt;imagename\u0026gt;\nList all of the images:\ndocker images\nExport the image:\ndocker save -o ~/container1.tar \u0026lt;imagename\u0026gt;\nRestore Load the Image:\ndocker load -i /root/container1.tar\nAdministration Access the bash prompt:\ndocker exec -i -t \u0026lt;containername\u0026gt; /bin/bash\nGet the Logs:\ndocker container logs \u0026lt;containername\u0026gt;\nBuild Docker Images Building a container and giving it a name\ndocker image buid -t \u0026lt;imagename\u0026gt; .\nTagging a Docker Image Get a list of the disk images to get the image id:\n`docker image ls\nTag the disk image for deployment:\ndocker tag \u0026lt;image_id\u0026gt; \u0026lt;tag_name\u0026gt;\nDocker SBOM You can generate a SBOM with the following tools\n Syft Grype " }, { "title":"Fastboot", "draft":"false", "date": "2018-04-13 15:04:14 -0600 -0600", "link": "https://wiki.punkcoder.com/topic/fastboot/", "content": " Fastboot Fastboot is one of the underlying tools that are located in android, it is the most basic level of communicating with the base android system. Can be used to boot or flash a device.\nGetting into fastboot adb reboot bootloader # starts the bootloader fastboot devices # lists devices Getting a list of all of the mapped partitions ls -l /dev/block/platform/soc/xxx/by-name/ Getting all of the Set Environment Variables in fastboot fastboot getvar all " }, { "title":"Forensics", "draft":"false", "date": "2018-04-13 15:04:14 -0600 -0600", "link": "https://wiki.punkcoder.com/topic/forensics/", "content": " Forensics Tools Autopsy Apache Tika " }, { "title":"Nikto", "draft":"false", "date": "2018-04-13 15:04:14 -0600 -0600", "link": "https://wiki.punkcoder.com/topic/nikto/", "content": " Nikto Application Scan of a Web Application Server, Includes some forced directory browsing.\nNikto -h \u0026lt;url\u0026gt;\n" }, { "title":"Pentesting: Apache", "draft":"false", "date": "2018-04-13 15:04:14 -0600 -0600", "link": "https://wiki.punkcoder.com/topic/pentesting-apache/", "content": " Apache Pentesting Bruteforcing htaccess with hydra hydra -l \u0026lt;user\u0026gt;s -P \u0026lt;passwordfile\u0026gt; -s \u0026lt;port\u0026gt; -f \u0026lt;ipaddress\u0026gt; http-get /\u0026lt;dir\u0026gt;/\n" }, { "title":"Pentesting: memcached", "draft":"false", "date": "2018-04-13 15:04:14 -0600 -0600", "link": "https://wiki.punkcoder.com/topic/pentesting-memcached/", "content": " Memchache Get a value from the cache memccat --servers=\u0026lt;server\u0026gt; --user=\u0026lt;user\u0026gt; --password=\u0026lt;password\u0026gt; \u0026lt;value\u0026gt; Getting User Access Script for brute forcing memcached password assuming that you know the user name.\n#! /bin/bash while read F ; do echo \u0026quot;Trying $F\u0026quot; if memcstat --servers=$1 --username=$2 --password=$F | grep -q Server ; then echo \u0026quot;Password Found: \u0026quot;$F break fi done \u0026lt; $3 " }, { "title":"Pentesting: nmap", "draft":"false", "date": "2018-04-13 15:04:14 -0600 -0600", "link": "https://wiki.punkcoder.com/topic/pentesting-nmap/", "content": " nmap nmap helpful commands Quick Port Scan (stealth syn): nmap -v -sS \u0026lt;ipaddress\u0026gt; Quick Port Scan (stealth syn) with Service Version: nmap -v -sS -sV \u0026lt;ipaddress\u0026gt; Port Scan (no dns, all ports): nmap -sV -n -p- \u0026lt;ipaddress\u0026gt; nmap scripts list nmap Scripts " }, { "title":"Static Code Analysis", "draft":"false", "date": "2018-04-13 15:04:14 -0600 -0600", "link": "https://wiki.punkcoder.com/topic/static-code-analysis/", "content": " Static Code Analysis Static code analysis is a tooling set that allows for the examination of source code in it\u0026rsquo;s raw form to look for security issues that may be present in the code base. Additionally it can help to find application functions that have been deprecated or that are utilized in appropriately.\n NIST List of Static Code Analysis Tools OWASP SAST Benchmark OWASP Benchmark Results " }, { "title":"Wiki Home", "draft":"false", "date": "2018-04-13 15:04:14 -0600 -0600", "link": "https://wiki.punkcoder.com/topic/home/", "content": " Wiki Home The goal of this wiki is to act as a placeholder for all of the random knowledge that I pick up in the course of my work and play. If you have found this and have any questions or items that you would like to dive into with more depth please feel free to reach out to me at punkcoder at protonmail dot com.\n" }, { "title":"gdb", "draft":"false", "date": "2018-04-13 15:04:14 -0600 -0600", "link": "https://wiki.punkcoder.com/topic/gdb/", "content": " gdb Compiling with support for gdb Compiling C with support for GDB: gcc -ggdb \u0026lt;file\u0026gt; -o \u0026lt;output\u0026gt; Copies the symbols from a binary: objcopy --only-keep-debug \u0026lt;binary\u0026gt; \u0026lt;debugfile\u0026gt; Remove the symbols from a binary: strip --strip-debug \u0026lt;binary\u0026gt; Completely removes the symbols from a binary: strip --strip-debug --strip-unneeded \u0026lt;binary\u0026gt; Add the symbols to the binary: objcopy --add-gnu-debuglink=\u0026lt;debugfile\u0026gt; \u0026lt;binary\u0026gt; Commands inside Only works if the source code is available\n Show source code: list or l Show source from line: list \u0026lt;line #\u0026gt; or l \u0026lt;line #\u0026gt; Show functions in code: info functions Show source files : info sources Show global variables: info variables Show scopes in which local varaiables can exist: info scope Show variables inside a scope: info scope \u0026lt;function\u0026gt; Show values inside the registers: info registers Add symbols at runtime: symbol-file \u0026lt;debugfile\u0026gt; Show Memory x/\u0026lt;count\u0026gt;\u0026lt;fmt\u0026gt;\u0026lt;size\u0026gt; \u0026lt;address\u0026gt; Formats o = octal x = hex d = decimal u = unsigned decimal t = bin f = float a = address i = instruction c = char s = string Size w = word Print the contents of a Variable: print \u0026lt;var\u0026gt; Dissasemble function: disassemble \u0026lt;func\u0026gt; Get help: help \u0026lt;cmd\u0026gt; Breakpoints Show all of the currently set breakpoints: info breakpoints Set a breakpoint in a function: break \u0026lt;func\u0026gt; Set a breakpoint at an address: break *\u0026lt;addr\u0026gt; Set a breakpoint at line number: break \u0026lt;line\u0026gt; Disable a breakpoint: disable \u0026lt;breakpoint #\u0026gt; Enable a breakpoint: enable \u0026lt;breakpoint #\u0026gt; Delete a breakpoint: delete \u0026lt;breakpoint #\u0026gt; Continuing from Breakpoint: continue Stepping: step Step into (step one instruction): stepi NM (Symbol listing) Run nm to get Symbol infromation Get sorted by address: nm -n \u0026lt;debug\u0026gt; Get external symbols: nm -e \u0026lt;debug\u0026gt; Get Storage: nm -S \u0026lt;debug\u0026gt; Full list available via: man nm NM Symbol Types A = Absolute Symbol B = In the Uninitialized Data Section (BSS) - Variables without initialization D = In the initialized Data Section - Variables with initialization N = Debugging Symbol T = In the Text Secion U = Symbol Undefined right now - Functions that are pulled from external libraries / dynamic loading Casing Lower case is Local Upper case is External strace Traces the System Calls. Shows you function by function call of the execution of the binary.\n execute: strace \u0026lt;binary\u0026gt; execute with timestamp: strace -t \u0026lt;bin\u0026gt; execute with relative timestamp: strace -r \u0026lt;bin\u0026gt; execute with output: strace -o \u0026lt;output\u0026gt; \u0026lt;bin\u0026gt; Limit output to only certian function calls: strace -e \u0026lt;func\u0026gt;, \u0026lt;func\u0026gt; \u0026lt;bin\u0026gt; Attach to a running process: sudo strace -p \u0026lt;pid\u0026gt;\n Get statistics of reference calls: strace -c \u0026lt;bin\u0026gt;\n Resources SecurityTube / Pentester Academy (SGDE) " }, { "title":"selinux", "draft":"false", "date": "2018-04-13 15:04:14 -0600 -0600", "link": "https://wiki.punkcoder.com/topic/selinux/", "content": " selinux Configuration Config files located @ /etc/sysconfig/selinux\nOperation Check the status of selinux: /usr/bin/sestatus Get the current state of selinux: getenforcing Listing the context of files: ls -lZ Listing the context of directory: ls -dZ \u0026lt;path\u0026gt; Get the contexts running in memory: ps -axZ Get the contexts of connections: netstat -tnlpZ Get managed ports context: semanage port -l Get all of the booleans: getsebool -a Set a boolean and make it permanent: setsebool \u0026lt;bool\u0026gt; \u0026lt;value\u0026gt; -P " }, { "title":"Security Training", "draft":"false", "date": "2018-04-13 14:56:07 -0600 -0600", "link": "https://wiki.punkcoder.com/topic/security-training/", "content": " Security Training Courses Sam Browne - Exploit Development for Beginners Sam Browne - Practical Malware Analysis Sam Browne - Hands-on Cryptography with Python (plus Blockchains) Technology Specific Active Directory Security Challenge Sites Hack this Site Over the Wire WeChall (chall mega site) " }, { "title":"Operational Security", "draft":"false", "date": "2018-04-13 14:54:29 -0600 -0600", "link": "https://wiki.punkcoder.com/topic/operational-security/", "content": " Operational Security Norse Attack Map OpSec for Linux Machines This information was collected from several locations and isn\u0026rsquo;t necessarily my Operational Setup, included here for individuals interested in a starting place or questions that they may have.\n```\nTools to install apt-get install secure-delete\nAliases to Set alias rm = \u0026ldquo;srm -rf\u0026rdquo;\nLinks ln -s /dev/null known_hosts ln -s /dev/null /var/log/syslog ln -s /dev/null /var/log/messges ```__\n log wiper from stuxnet anti-forensics " }, { "title":"", "draft":"false", "date": "0001-01-01 00:00:00 +0000 UTC", "link": "https://wiki.punkcoder.com/topic/android/", "content": " Android Testing Codes Code Description ##4636## Display information about Phone, Battery and Usage statistics ##7780## Restting your phone to factory state-Only deletes application data and applications *2767*3855# It’s a complete wiping of your mobile also it reinstalls the phones firmware ##34971539## Shows completes information about the camera ##7594## Changing the power button behavior-Enables direct poweroff once the code enabled ##273283*255663282## For a quick backup to all your media files ##197328640## Enabling test mode for service activity ##232339## OR ##526## Wireless Lan Tests ##232338## Displays Wi-Fi Mac-address ##1472365## For a quick GPS test ##1575## A Different type GPS test ##0283## Packet Loopback test ##0##* LCD display test ##0673## OR ##0289## Audio test ##0842## Vibration and Backlight test ##2663## Displays touch-screen version ##2664## Touch-Screen test ##0588## Proximity sensor test ##3264## Ram version ##232331## Bluetooth test ##7262626## Field test ##232337#*# Displays bluetooth device address ##8255## For Google Talk service monitoring ##49862650468##* PDA, Phone, Hardware, RF Call Date firmware info ##1234## PDA and Phone firmware info ##1111## FTA Software version ##2222## FTA Hardware verion ##44336## Displays Build time and change list number *#06# Displsys IMEI number ##8351## Enables voice dialing logging mode ##8350## Disables voice dialing logging mode ##778 (+call) Brings up Epst menu Courtesy of Android Hidden Codes " }, ];