Хакер | Этичный хакинг с Михаилом Тарасовым (Timcore)
1.64K subscribers
941 photos
53 videos
85 files
3.4K links
Обучение:

- Pentesting
- Социальная инженерия
- Проникновение
- Защита
- Работа с эксплойтами
- Аудит безопасности Обратная связь: admin@timcore.ru @timcore1
Download Telegram
#hackthebox
#htb
#hacking

HackTheBox - BroScience

00:00 - Intro
00:51 - Start of nmap
02:30 - Finding some vulnerable-looking parameters
03:50 - Testing some basic things for LFI, finding a WAF blocking ../. Double encoding it to get passed
07:11 - Start of writing a script to abuse this LFI and crawl/download all the php source
10:30 - Making the script recursive, so it will check pages downloaded for new links
16:50 - Making the script save the files
19:40 - Opening the code in Visual Studio Code, and showing off Snyk's static code anlysis to highlight a Unserialization vuln
22:20 - Identifying how the site generates activation codes upon registration identifying an insecure use of SRAND(). Generating our own activation code
25:30 - Exploiting the PHP Unserialization by finding a vulnerable gadget (wakeup) which will save a file
27:45 - Building a deserialization object to download a file off our server and write it to the web directory
32:08 - EDIT: Talking about webserver hardening (allow_url_fopen in php) and how it would slow down this attack
35:00 - EDIT: Poisoning our PHP Session with PHP Code as our username, then building an object to copy that to the server so don't need to use a remote host
41:38 - Getting a shell on the box, dumping credentials from postgres
44:55 - Attempting to crack the passwords, failing, checking the source code to identify there is a hidden salt. Then cracking the passwords
51:25 - Passwords cracked logging in as bill
55:10 - Using pspy to identify a script runs to renew certificates
57:15 - Going over the bash script and identifying a command injection vulnerability.
1:01:45 - Failing for a bit because I didn't change the certificate time, then changed too much at once which caused me more problems
1:06:04 - Finding the CheckEnd parameter, setting our days equal to one but our payload doesn't work
1:08:15 - Putting the payload in $(), and getting root to the box
01:10:20 - Just making sure we fully understood why our first attempts failed

https://www.youtube.com/watch?v=kyPYfqMYQm8
По книге «Хакинг bWAPP (buggy web application). Эксплуатация 100+ уязвимостей.», разобрал полностью все уязвимости категории
A2 - Broken Auth. & Session Mgmt (Broken Authentication & Session Management).
Их всего 11 разновидностей. Сегодня описал +5 уязвимостей:

1. Broken Authentication - CAPTCHA Bypassing - уровень low.
2. Broken Authentication - Forgotten Function - уровень low.
3. Broken Authentication - Insecure Login Forms - уровень low.
4. Broken Authentication - Logout Management - уровень low.
5. Broken Authentication- Password Attacks - уровень low.
6. Broken Authentication - Weak Passwords - уровень low.
7. Session Management – Administrative Portals - уровень low.
8. Session Management - Cookies (HTTP Only) - уровень low.
9. Session Management- Cookies (Secure) - уровень low.
10. Session Management - Session ID in URL- уровень low.
11. Session Management - Strong Sessions - уровень low.
#kali_linux
#aws
#cloud_security

#71 Kali Linux для продвинутого тестирования на проникновение. Сканирование уязвимостей и эксплуатация приложений в EC2. Часть 2.

Здравствуйте, дорогие друзья.

Давайте продолжим и определим список экземпляров, доступных для профиля RCE, который мы создали, выполнив в терминале следующую команду:

sudo aws ec2 describe-instances --profile <Profile Name>

Это должно предоставить детали экземпляра.

Подробнее: https://timcore.ru/2023/04/19/71-kali-linux-dlja-prodvinutogo-testirovanija-na-proniknovenie-skanirovanie-ujazvimostej-i-jekspluatacija-prilozhenij-v-ec2-chast-2/
По книге «Хакинг bWAPP (buggy web application). Эксплуатация 100+ уязвимостей.», разобрал полностью все уязвимости категории
A4 - Insecure Direct Object References

Их всего 3 разновидности. Сегодня описал +3 уязвимости:

1. Insecure DOR (Change Secret) - уровень low.
2. Insecure DOR (Reset Secret) - уровень low.
3. Insecure DOR (Order Tickets) - уровень low.

Понравилась 3-я уязвимость, потому что при ее эксплуатации можно покупать билеты в кино бесплатно., без должной аутентификации и авторизации. Я получил доступ к параметрам заказа билетов, через BurpSuite, и осуществил возможность изменить цену билетов на более низкую, либо вообще бесплатно.
Отзыв по 1-й главе моей книги: «Хакинг bWAPP (buggy web application). Эксплуатация 100+ уязвимостей.» от ученицы.

Важен фидбек, чтобы я понимал, как воспринимается информация другими людьми.
#hackthebox
#htb
#hacking

HackTheBox - Vessel

00:00 - Introduction talking about how this box is about finding CVE's and building an exploit based upon exploit
00:50 - Start of nmap
03:00 - Running gobuster and showing the importance of using multiple wordlists.
05:00 - Attempting to register an account, which shows the endpoint /api/register but /api/ returns a 404
06:10 - Showing that raft-small-words wordlist won't discover .git but commons.txt will because commons has .git/HEAD
08:25 - Running Git-Dumper to extract the source then looking at the code
09:00 - Showing the vulnerable code and how secure the code appears at first glance without knowing specifics about the library
10:00 - Googling MySQLJS Sql Injection and showing how you would have found this exploit
11:30 - Showing how you could have found it blindly, passing an object into the SQL Query and doing SQL Injection on NodeJS with MySQL
19:00 - Logging in and finding OpenWebAnalytics version 1.7.3, finding a CVE and writeup for the vulnerability
22:30 - Showing the piece missing from the writeup that tells us how we can retrieve the cache file that can be used to reset a password
24:40 - Going over the code, and figuring out how the filename is generated.
28:30 - FIXED PART, sorry cut out a piece on how I traced the function back to how it generates the filname
31:29 - Resetting the admin account from the exposed cache file
35:39 - Exploiting the Mass Assignment Vulnerability to write to a configuration file, to increase log verbosity, file name of log, and then poisoning the log
46:09 - Reverse shell returned
48:39 - Downloading a custom password generator that appears to be a compiled python executable.
51:24 - Running Pyinsxtractor to extract the pyc files out of the exe and then using Docker to match the python version which will allow uncompyle to convert pyc to py files
56:19 - Starting the docker and copying our password generator into it
57:29 - Showing the vulnerable password generation function, it is just using millisecond as a seed
57:49 - Building a script to generate all possible passwords, turns out it fails because Windows and Linux randomization is different
1:00:29 - Running pdf2john to generate a hash for the pdf file
1:02:19 - Running the script on windows to generate different passwords, then cracking ethans password with john
1:05:39 - Looking at SetUID Files, finding PINNS from CRI-O which is a binary related to Kubernetes
1:07:39 - There's no man page for the PINNS binary, so looking at the source code to change the kernel parameter for core dumps
1:11:00 - Creating an exploit script, poisoning the core dump parameter, and generating a dump to execute our script and getting root

https://www.youtube.com/watch?v=ZANv0DlrTN8
#news

У криптоплатформы Bitrue похитили 23 млн долларов

Криптовалютная биржа Bitrue сообщила, что была взломана неизвестными хакерами. В результате атаки на один из горячих кошельков платформа потеряла активы на сумму 23 миллиона долларов.

Источник: https://xakep.ru/2023/04/19/bitrue-hacked/
#kali_linux
#cloud
#aws

#72 Kali Linux для продвинутого тестирования на проникновение. Сканирование уязвимостей и эксплуатация приложений в EC2. Часть 3.

Здравствуйте, дорогие друзья.

Мы можем видеть резервирование и детали экземпляра с imageID и его размещением. Далее, внутри детали, мы можем найти общедоступный IP-адрес и DNS-имя экземпляра, вместе со всеми сведениями о сети и подсети.

Подробнее: https://timcore.ru/2023/04/21/72-kali-linux-dlja-prodvinutogo-testirovanija-na-proniknovenie-skanirovanie-ujazvimostej-i-jekspluatacija-prilozhenij-v-ec2-chast-3/
Media is too big
VIEW IN TELEGRAM
1. Разбор уязвимости приложения bWAPP, категории А2 - Broken Auth. - CAPTCHA Bypassing
#hackthebox
#htb
#hacking

HackTheBox - Investigation

00:00 - Introduction
01:00 - Start of nmap
02:00 - Start of gobuster
04:00 - Discovering an upload form, looking for where things get uploaded
05:50 - The upload gives us ExifTool output, including the version number to show it is vulnerable to CVE-2022-23935
08:11 - You should really watch "The Perl Jam"
08:40 - Showing the weird syntax of perl's file open and how | leads to RCE
16:15 - Back to the box, exploiting and getitng a shell
20:00 - Reverse shell returned, looking at the uploaded files
22:35 - Running LinPEAS to discover a cron
27:00 - There's an outlook email message with an attachment. Copying it then converting to eml format and extracting the file
32:45 - The file was an windows event log. Using Chainsaw to search through the logs
38:30 - Using Chainsaw and JQ to parse the Successful and Failed logins
42:25 - In the failed logins field, there's a password as a username and logging in as smorton
44:35 - There's a binary on this box, copying it to us and opening in Ghidra
45:30 - Start of reversing, just showing strings and finding out where the get loaded in the program
47:00 - Running the binary in GDB and showing how arguments work, then renaming and retyping variables to have decompiled output make more sense
51:30 - Retyping done, renaming a few variables to make things easier to read
53:45 - Cleaning up the curl_easy_setopt, code by creating an enum in C then using Ghidra to "Parse C Source"
59:20 - Now that the code is cleaned up, it is obvious the program executes perl scripts... Funny thing is the perl binary can execute non-perl scripts
1:01:05 - Showing there is also a race condition in the binary because the curl downloads to CWD and even thoe its owned by root we can rename it and take control over the file

https://www.youtube.com/watch?v=X5hVEuWmehk
#kali_linux
#cloud
#aws

#73 Kali Linux для продвинутого тестирования на проникновение. Проверка неправильной конфигурации корзины S3.

Здравствуйте, дорогие друзья.

S3 обычно используется организациями для хранения документов, кода, загрузки файлов и т. д. Как правило, корзина может быть общедоступной или частной. Когда она общедоступна, все пользователи могут просматривать содержимое, а когда она частная, только выбранный набор пользователей может просматривать содержимое. В этом разделе мы рассмотрим идентификацию сегментов S3 и использование неправильной конфигурации для получения доступа к внутренней инфраструктуре AWS.

Подробнее: https://timcore.ru/2023/04/24/73-kali-linux-dlja-prodvinutogo-testirovanija-na-proniknovenie-proverka-nepravilnoj-konfiguracii-korziny-s3/
#news

Операторы малвари Medusa утверждают, что «слили» исходный код Bing и Cortana

Вымогательская группировка Medusa утверждает, что опубликовала в открытом доступе внутренние материалы, украденные у компании Microsoft, включая исходные коды Bing, Bing Maps и Cortana. Представители Microsoft пока не прокомментировали заявления хакеров, но ИБ-специалисты говорят, что утечка содержит цифровые подписи продуктов компании, многие их которых актуальны.

Источник: https://xakep.ru/2023/04/20/medusa-microsoft/
По книге «Хакинг bWAPP (buggy web application). Эксплуатация 100+ уязвимостей.», разобрал +3 уязвимости категории А3 - Cross-Site Scripting (XSS):

Уязвимость Cross-Site Scripting (XSS) - Reflected (Login Form) - low.
Уязвимость Cross-Site Scripting (XSS) - Reflected (phpMyAdmin) - low.
Уязвимость Cross-Site Scripting (XSS) - Reflected (PHP_SELF) - low.

Всего разобрал 56 уязвимостей. А это почти половина, от общего списка.
#kali_linux
#cloud

#74 Kali Linux для продвинутого тестирования на проникновение. Использование недостатков разрешений безопасности в облаке. Часть 1.

Здравствуйте, дорогие друзья.

Ниже перечислены наиболее распространенные уязвимости в облачных сервисах AWS:

• Чрезмерное количество общедоступных подсетей. Большинство организаций используют VPC по умолчанию (виртуальное частное облако), которое встроено в AWS и вносит несколько изменений при использовании AWS. Однако этот подход окажется опасным во многих случаях (примером может служить крипто-вымогатель на основе ботнета). Публичные подсети доступны любому пользователю в Интернете, потенциально раскрывая данные, которые не должны быть общедоступными.

Подробнее: https://timcore.ru/2023/04/26/74-kali-linux-dlja-prodvinutogo-testirovanija-na-proniknovenie-ispolzovanie-nedostatkov-razreshenij-bezopasnosti-v-oblake-chast-1/
#news
#ddos

Количество DDoS-атак возросло на 22%

Аналитики компании Qrator Labs представили статистику DDoS-атак в первом квартале 2023 года. Оказалось, что общее число атак выросло на 22%, но их продолжительность заметно сократилась, и злоумышленники стали более тщательно выбирать жертв.

Источник: https://xakep.ru/2023/04/26/q1-2023-ddos-attacks/
По книге «Хакинг bWAPP (buggy web application). Эксплуатация 100+ уязвимостей.», разобрал все уязвимости категории А3 - Cross-Site Scripting (XSS). В виртуальной машине их 19 разновидностей:

1. Уязвимость Cross-Site Scripting (XSS) - Reflected (GET) - уровень low.
2. Уязвимость Cross-Site Scripting (XSS) - Reflected (POST) - уровень low.
3. Уязвимость Cross-Site Scripting (XSS) - Reflected (JSON) - уровень low.
4. Уязвимость Cross-Site Scripting (XSS) - Reflected (ALAX/JSON) - уровень low.
5. Уязвимость Cross-Site Scripting (XSS) - Reflected (AJAX/XML) - уровень low.
6. Уязвимость Cross-Site Scripting (XSS) - Reflected (Back Button) - уровень low.
7. Уязвимость Cross-Site Scripting (XSS) - Reflected (Custom Header) - уровень low.
8. Уязвимость Cross-Site Scripting (XSS) - Reflected (Eval) - уровень low.
9. Уязвимость Cross-Site Scripting (XSS) - Reflected (HREF) - уровень low.
10. Уязвимость Cross-Site Scripting (XSS) - Reflected (Login Form) - уровень low.
11. Уязвимость Cross-Site Scripting (XSS) - Reflected (phpMyAdmin) - уровень low.
12. Уязвимость Cross-Site Scripting (XSS) - Reflected (PHP_SELF) - уровень low.
13. Уязвимость Cross-Site Scripting (XSS) - Reflected (Referer) - уровень low.
14. Уязвимость Cross-Site Scripting (XSS) - Reflected (User-Agent) - уровень low.
15. Уязвимость Cross-Site Scripting (XSS) - Stored (Blog) - уровень low.
16. Уязвимость Cross-Site Scripting (XSS) - Stored (Change Secret) - уровень low.
17. Уязвимость Cross-Site Scripting (XSS) - Stored(Cookies) - уровень low.
18. Уязвимость Cross-Site Scripting (XSS) - Stored (SQLiteManager) - уровень low.
19. Уязвимость Cross-Site Scripting (XSS) - Stored (User-Agent) - уровень low.
#kali_linux
#cloud
#cloud_security

#75 Kali Linux для продвинутого тестирования на проникновение. Использование недостатков разрешений безопасности в облаке. Часть 2.

Здравствуйте, дорогие друзья.

Давайте изучим экземпляры, доступные для этого профиля, запустив sudo aws ec2 describe-instances –region us-east-1 –profile lambda-solus. Команда должна перечислить сведения об экземпляре, вместе с общедоступным IP-адресом.

Подробнее: https://timcore.ru/2023/04/28/75-kali-linux-dlja-prodvinutogo-testirovanija-na-proniknovenie-ispolzovanie-nedostatkov-razreshenij-bezopasnosti-v-oblake-chast-2/
#kali_linux
#cloud

#76 Kali Linux для продвинутого тестирования на проникновение. Обфускация журналов CloudTrail.

Здравствуйте, дорогие друзья.

CloudTrail — это служба Amazon, которая отслеживает любые действия, совершаемые пользователями. Предположим, что злоумышленники теперь имеют привилегированный доступ к среде, и они смогут изменить настройки.

Подробнее: https://timcore.ru/2023/04/29/76-kali-linux-dlja-prodvinutogo-testirovanija-na-proniknovenie-obfuskacija-zhurnalov-cloudtrail/
Здравствуйте, дорогие друзья.

Важная информация для тех, кто приобретал у меня курс «Этический взлом». Суть состоит в том, что Вы можете бесплатно получить обновление данного курса, в виде 4-х дополнительных модулей.
А именно, отправлю разбор уязвимостей по методологии OWASP Top-10:

7-й модуль, в формате pdf:
А1 - Injection:

8-й модуль, в виде видеоуроков:
A2 - Broken Auth. & Session Mgmt

9-й модуль, в формате pdf:
А3 - Cross-Site Scripting (XSS)

10-й модуль, в формате pdf:
А4 - Insecure Direct Object References

Более того, бесплатны будут все категории по OWASP Top-10, а их 10 соответственно, но пока готовы 4-ре.

Вам просто остается следить за обновлениями в паблике, и писать мне при первом появлении материалов.

Всем хорошего дня, и happy hacking! 😊
#kali_linux
#nac

#77 Kali Linux для продвинутого тестирования на проникновение. Обход контроля безопасности.

Здравствуйте, дорогие друзья.

Пандемия COVID-19 привела к тому, что многие организации полностью перешли на удаленную работу в 2020 году, и это значительно увеличило риск, связанный с конечными устройствами, которые используют удаленные работники. Развитие технологии Endpoint Detection and Response (EDR) с начала 2018 г., теперь появилась как замена традиционному антивирусному программному обеспечению из-за различных типов инцидентов безопасности, особенно работой изощренных программ-вымогателей.

Подробнее: https://timcore.ru/2023/05/02/77-kali-linux-dlja-prodvinutogo-testirovanija-na-proniknovenie-obhod-kontrolja-bezopasnosti/