Седмицата (16–21 септември)

Post Syndicated from Йовко Ламбрев original https://www.toest.bg/sedmitsata-16-21-septemvri/

Асансьорът на властта в България е заседнал между 1989 г. и началото на XXI век.

Седмицата (16–21 септември)

Така започва тазседмичният политически анализ на Емилия Милчева за „Тоест“. А асансьорът е претоварен с партийни апаратчици и спорни лидери, добавя дежурният ни редакционен екип. За съпротивата на политическата върхушка в България да освободи хоризонта пред страната ни, за неформалните мрежи на влияние сред старите партийни елити и колко наивно е да очакваме различни листи за изборите на 27 октомври – четете в статията „Мудният асансьор на властта в България“.

Демокрацията е крехка. А най-уязвима и беззащитна е, когато бива атакувана чрез злоупотреба с инструменти, които иначе са създадени да произвеждат повече демокрация. Опорочени избори или референдуми, користно законотворчество, завладени институции, призовани да я пазят. Така е не само у нас. Но в навечерието на най-новата предизборна кампания в България местната фабрика за политически популизъм работи на пълни обороти. Дори там, където очакванията това да не се случва, са най-високи. За поредното фундаментално глупаво политическо действие на ПП–ДБ разказва Светла Енчева в статията си „Смяна на пола на деца? Някой разбра ли какво от ПП–ДБ (не) искат да се забрани?“.

И както от една страна се създава усещане, че всички са се втурнали да решават несъществуващ проблем (част от върволица впрочем), така пък съществени проблеми биват замитани под килима. Например борбата с употребата на наркотици. По този повод Надежда Цекулова разговаря с Юлия Георгиева, председател на Фондация „Център за хуманни политики“, чиято основна цел е осигуряване на помощ за попадналите в капана на наркотиците.

И докато сме на тема „здравеопазване“, на 22 септември отбелязваме обявяването на независимостта на България, но и още нещо – Международния ден на нарколепсията. Напълно е възможно да не знаете какво е това, защото е рядко хронично неврологично заболяване. То нарушава способността на човешкия мозък да регулира цикъла сън–будност и води след себе си драматично влошаване на качеството на живот. На това отгоре се диагностицира бавно, а достъпът до лечение е труден. Използвайте повода, за да се информирате за нарколепсията, защото страдащите и близките им имат нужда от подкрепа и емпатия.

„Мила ваканция… Къде си, когато най ми трябваш?“, пита Донка Дойчева-Попова в новата си статия в рубриката ни „Възможното образование“. В текста си тя повдига темата за силно неравномерното разпределение на времето за учене и ваканции в графика на българските ученици, които разполагат с една от най-дългите летни ваканции, но с малко други почивки през учебната година. А това, оказва се, изобщо не е незначителен проблем.

През седмицата изтече срокът, в който беше възможно България да промени позицията си относно поредния опит за отслабване на #chatcontrol – криптирането на личната кореспонденция в ЕС, за което вече писахме през юни и юли. Според източници на „Тоест“ най-вероятно позицията на страната ни ще си остане двусмислена, тоест формално няма да подкрепим отслабване на криптирането открай докрай, но ще приемем компромиси, които ще позволяват обследване на съдържанието на устройства на потребителите чрез алгоритми (и вероятно изкуствен интелект). Общото решение на Брюксел ще стане ясно на 10 октомври.

Доставчиците на приложения за криптирани съобщения Signal и Threema вече обявиха, че никога няма да се съгласят да включат подобни процедури за наблюдение в своите приложения и по-скоро ще прекратят дейността си в ЕС.

Обикновено когато говорим за технологии, гласовете на технократите (включително на т.нар. експерти) и предприемачите превземат обществения дебат. Една от гигантските грешки, които повтаряме непрекъснато, е, че допускаме да бъде заглушен гласът на хуманитаристите.

Във връзка с това нека напомним, че на 10 септември излезе новата книга на популярния историк, философ и мислител Ювал Ноа Харари „Nexus. Кратка история на информационните мрежи от каменната епоха до изкуствения интелект“. За български превод ще трябва да изчакаме някакво време, но междувременно може да настроите очакванията си с първия поглед на колегите от „Капитал“ към книгата. Или ако сте склонни да отделите два часа от свободното си време (и да пренебрегнете лепкавостта на заглавието), препоръчвам да изгледате това интервю, което освен препратките към теми от новата и предишните му книги съдържа интересни гледни точки към най-актуалните теми от ежедневието ни.

А в допълнение: на тези от вас, които се вълнуват от теми като неприкосновеност на дигиталната кореспонденция, правата ни в цифровия свят, етичните казуси около изкуствения интелект или отровните бизнесмодели на днешните високотехнологични компании, силно препоръчвам да намерят време и за интервюто на Меридит Уитакър за WIRED. Тя е директор на Фондация Signal Technology и се грижи за развитието на приложението Signal Messenger, превърнало се в златен стандарт за сигурна комуникация. Уитакър също е и изследователка, активистка за човешки права и гласовит борец срещу всякакви административни и политически опити за отслабване на криптирането, ползвано за защита на личната кореспонденция. Ето малко задъхани реплики от интервюто.

Монополистичната хегемония е наистина резултатен начин да трупаш потребители. Но това не печели сърцата и умовете. (…) Това е принуда.

Търсенето на алтернатива никога не е било по-силно. (…) Знам, че технологиите, направени по различен начин, са възможни.

Не става въпрос за липса на идеи или възможности. Става въпрос за това, че трябва сериозно да започнем да приемаме промените, необходими за изграждането на технологии, които отхвърлят наблюдението и централизирането на контрола – и тази необходимост вече е очевидна за всички.

„Питали Пророка на исляма за виното и за хазарта. В тях, казва той, има голям грях, но и изгоди“, пише Атанас Шиников в първата част на новия си текст от рубриката „Ориент кафе“, озаглавен „За ориенталския махмурлук, Корана и домашнярката“. И както вече сте се досетили, ще се опита да убеди читателите на „Тоест“, че има легитимен начин хем да живееш според предписанията на Корана, хем да си пийваш. И дори ще ни го докаже с исторически източници.

Да завършим с литературна препоръка. Към една забележителна, но и трудна книга ни връща тази седмица Антония Апостолова в рубриката ни „На второ четене“ – романа „Годините“ на френската нобелистка Ани Ерно. Антония я определя като квазидокументален архив на едно поколение и на следвоенните години на XX век, през които „прогресът е хоризонтът на съществуването“. Време, което Ерно ни обещава да спечели битката с настоящето.

Приятно четене!

Metasploit Weekly Wrap-Up 09/20/2024

Post Syndicated from Christopher Granleese original https://blog.rapid7.com/2024/09/20/metasploit-weekly-wrap-up-09-20-2024/

New module content (3)

update-motd.d Persistence

Metasploit Weekly Wrap-Up 09/20/2024

Author: Julien Voisin
Type: Exploit
Pull request: #19454 contributed by jvoisin
Path: linux/local/motd_persistence

Description: This adds a post module to keep persistence on a Linux target by writing a motd bash script triggered with root privileges every time a user logs into the system through SSH.

WordPress LiteSpeed Cache plugin cookie theft

Authors: Rafie Muhammad and jheysel-r7
Type: Exploit
Pull request: #19457 contributed by jheysel-r7
Path: multi/http/wp_litespeed_cookie_theft
AttackerKB reference: CVE-2024-44000

Description: This adds an exploit module for a WordPress Plugin called LiteSpeed (CVE-2024-44000). On the vulnerable plugin, when the Debug Logs are enabled, it is possible to leak authentication cookies of logged in users, the msf module will use the stolen cookies to upload and execute a plugin able to spawn a meterpreter session.

Windows Kernel Time of Check Time of Use LPE in AuthzBasepCopyoutInternalSecurityAttributes

Authors: jheysel-r7 and tykawaii98
Type: Exploit
Pull request: #19345 contributed by jheysel-r7
Path: windows/local/cve_2024_30088_authz_basep
AttackerKB reference: CVE-2024-30038

Description: This adds a Windows LPE post module that exploits CVE-2024-30088. Once the exploit is executed through a running meterpreter session, it will open another one with NT AUTHORITY/SYSTEM privileges.

Enhancements and features (3)

  • #19414 from cdelafuente-r7 – Adds some missing constants for the Kerberos LoginScanner as defined in the documentation. This also defines the default connection_timeout value in #set_sane_defaults as defined here.
  • #19443 from jvoisin – Removes some redundant code from lib/msf/core/payload/php.rb.
  • #19445 from jvoisin – Makes minor improvements of lib/msf/core/payload/php.rb.

Bugs fixed (1)

  • #19449 from zeroSteiner – This fixes an issue in the exploit for CVE-2022-0995 where it would crash with an exception while printing a message regarding why it failed.

Documentation added (1)

  • #19452 from zeroSteiner – This improves the Metasploit’s documentation explaining how to setup a Meterpreter handler over Ngrok port-forwarding.

You can always find more documentation on our docsite at docs.metasploit.com.

Get it

As always, you can update to the latest Metasploit Framework with msfupdate
and you can get more details on the changes since the last blog post from
GitHub:

If you are a git user, you can clone the Metasploit Framework repo (master branch) for the latest.
To install fresh without using git, you can use the open-source-only Nightly Installers or the
commercial edition Metasploit Pro

Metasploit Weekly Wrap-Up 09/20/2024

pcp: pmcd network daemon review (SUSE Security Team Blog)

Post Syndicated from jzb original https://lwn.net/Articles/991091/

The SUSE Security Team Blog has a detailed review of the Performance Co-Pilot (PCP) 6.2.1 release:

The rather complex PCP software suite was difficult to judge just from
a cursory look, so we decided to take a closer look especially at
PCP’s networking logic at a later time. This report contains two CVEs
and some non-CVE related findings we also gathered during the
follow-up review.

CVE-2024-45769,
a flaw that could allow an attacker to send crafted data to crash
pcmd, and CVE-2024-45770,
which could allow a full local root exploit from the pcp user to root,
have been addressed in the 6.3.1
release of PCP.

Automate detection and response to website defacement with Amazon CloudWatch Synthetics

Post Syndicated from Agus Komang original https://aws.amazon.com/blogs/security/automate-detection-and-response-to-website-defacement-with-amazon-cloudwatch-synthetics/

Website defacement occurs when threat actors gain unauthorized access to a website, most commonly a public website, and replace content on the site with their own messages. In this blog post, we show you how to detect website defacement, and then automate both defacement verification and your defacement response by using Amazon CloudWatch Synthetics visual monitoring canaries. Canaries are configurable scripts that run on a schedule and compare screenshots taken during a canary run with screenshots taken during a baseline canary run. If the discrepancy between the two screenshots exceeds a threshold percentage, the canary fails. We will show you how to quickly deploy a maintenance page through AWS WAF after you verify the defacement.

Common causes of defacement include unauthorized access, SQL injection, cross-site scripting (XSS), or malware. You can use AWS services such as AWS WAF, Amazon Route 53, and Amazon GuardDuty to put additional mechanisms in place to help improve your security posture.

Solution overview

The architectural diagram in Figure 1 shows a typical web application where users access the application by using Amazon CloudFront protected by AWS WAF.

Figure 1: Defacement detection and response with CloudWatch Synthetics

Figure 1: Defacement detection and response with CloudWatch Synthetics

As shown in the diagram, the solution consists of two parts: 1) visual monitoring for defacement detection, and 2) automation of the verification and defacement response.

Part 1: Visual monitoring for defacement detection

Defacement detection uses CloudWatch Synthetics visual monitoring canaries to perform visual monitoring. You can create canaries in CloudWatch Synthetics that periodically take a screenshot of the monitored URLs. Because the canaries only need network access to the monitored URLs, you can implement this solution without affecting the application or modifying its code. For more details on how to create CloudWatch Synthetics visual monitoring canaries, see Visual monitoring of applications with Amazon CloudWatch Synthetics.

You can use the CloudWatch Synthetics visual monitoring blueprint to compare screenshots taken during a canary run with screenshots taken during a baseline canary run. This solution is suitable for static a target=”_blank” hrefs where a discrepancy between the two screenshots that exceeds a threshold percentage could indicate a possible defacement attempt, causing the canary to trigger a failure event.

The threshold percentage is defined by the visual variance that occurs when the current screenshot differs from the baseline screenshot that was captured during the first run of the canary. To reduce false positives, you can adjust the threshold for detecting visual variance.

In the following script, we updated the visual variance to 5% in the visual monitoring blueprint:

# Setting Threshold to 5%
syntheticsConfiguration.withVisualVarianceThresholdPercentage(5);

Figure 2 shows the first baseline screenshot of a webpage with visual variance set to 5%.

Figure 2: Image taken during a baseline canary run

Figure 2: Image taken during a baseline canary run

Figure 3 shows the visual variance of a defaced webpage. In this case, the visual variance was set to 5% in the script, and the visual variance detected was 30.92%.

Figure 3: Failed canary run due to differences from the baseline screenshot

Figure 3: Failed canary run due to differences from the baseline screenshot

Figure 4 shows a webpage with dynamic content that triggered a false positive because the visual monitoring canary was unable to differentiate between real dynamic content and variation from the baseline. In this case, the visual variance was set to 5% in the script, and the visual variance detected was 5.25%.

Figure 4: Dynamic content in Feedback form that triggered canary failure

Figure 4: Dynamic content in Feedback form that triggered canary failure

You can select the dynamic content to exclude it from the visual comparison for subsequent canary runs. To exclude the dynamic content, edit the baseline screenshot in CloudWatch Synthetics. Using a simple click-drag, you can select the area to exclude from visual comparison for subsequent canary runs, as shown in Figure 5.

Figure 5: Exclusion of dynamic content

Figure 5: Exclusion of dynamic content

If your applications have additional areas with dynamic content, you can select more than one area to exclude from comparison.

Figure 6 shows a successful canary run after exclusion of the area that contains the dynamic content.

Figure 6: Canary succeeded after the exclusion of dynamic content

Figure 6: Canary succeeded after the exclusion of dynamic content

You can automate the defacement response by using Amazon EventBridge rules to trigger Amazon Simple Notification Service (Amazon SNS) when a canary run fails. By using the publish-subscribe pattern, you can customize and add on the response functions based on your organization’s needs.

The following shows the event pattern script in EventBridge. Make sure to update the canary name with the name of the CloudWatch Synthetics visual monitoring canary that you created earlier to serve as the event source.

 // Event patterns in EventBridge to get event source from canary

{
  "source": ["aws.synthetics"],
  "detail-type": ["Synthetics Canary TestRun Failure"],
  "detail": {
    "canary-name": ["<replace-with-canary-name>"]
  }
}

When the event pattern matches the rules that you configured in EventBridge, the Amazon SNS topic triggers the approval flow, as shown in Figure 7. This begins automation of the verification and defacement response, which we describe in the next section.

Figure 7: Amazon SNS topic triggered when the event pattern matches

Figure 7: Amazon SNS topic triggered when the event pattern matches

Part 2: Automation of the verification and defacement response

Figure 8 outlines how to automate the verification and defacement response. When alerts are received upon detection of defacement, the notified team can choose to verify the defacement. This defacement monitor uses CloudWatch Synthetics while maintaining the flexibility to configure and verify threshold settings through manual verification. If you are confident in your thresholds, you can bypass the approval flow and directly block site traffic by using an AWS WAF rule during a defacement attempt.

Figure 8: Defacement detection and response with CloudWatch Synthetics

Figure 8: Defacement detection and response with CloudWatch Synthetics

As shown in the diagram, this is what the traffic flow looks like during a defacement:

  1. The canary from the CloudWatch Synthetics visual monitor identifies defacement through visual variance against the baseline screenshot taken during the first canary run and emits an event.
  2. If the emitted event matches the rules configured in EventBridge, Amazon SNS is triggered. This triggers the subscribed AWS Lambda function that sends a Slack notification with the event details asking for approval.
  3. The notified team receives a Slack message about the defacement and makes an approval decision.
  4. If approval is granted, an AWS WAF rule is added to block traffic and a maintenance page is served to users.
  5. The user that accessed the origin is shown a maintenance page served by AWS WAF.

Although this example shows the use of Slack as an approval mechanism, you can use the communication mechanism of your choice.

Conclusion

In this post, you learned how to use CloudWatch Synthetics to monitor for defacement and display a maintenance page through AWS WAF and CloudFront while you work on recovering the service. You also learned how to use manual approval to identify the optimal threshold and exclude the area that contains dynamic content to reduce false positives.

Although most web applications already use CloudFront and AWS WAF, you can integrate this solution to your existing environment without affecting the application or modifying its code. This solution helps detect potential defacement, providing you with an additional layer of protection for your environment.

We recommend that you explore the capabilities of CloudWatch Synthetics monitoring to detect and use the capabilities of the cloud through services such as EventBridge, Amazon SNS, and Lambda to enable automation. This can help you proactively protect your application against defacement attempts.

 
If you have feedback about this post, submit comments in the Comments section below. If you have questions about this post, contact AWS Support.

Agus Komang
Agus Komang

Agus is a Principal Solutions Architect (Security) at AWS. He helps public sector customers to build secure, resilient, and compliant workloads in the cloud.
Jessica Ang
Jessica Ang

Jessica is a Solutions Architect at AWS specializing in security. She helps customers to innovate securely and efficiently through the use of AWS services and security automation.