Meltdown/Spectre Script Verifikation Linux

Neu ist "Kernel support for IBRS: YES ", da Firmware Fehlanzeige ohne Auswirkungen. Hier liegt eher die Hoffnung auf Kernel 4.15.
(Mint 18.3 auf einem Ivy Bridge i5-3450/Z77)

Spectre and Meltdown mitigation detection tool v0.30

Checking for vulnerabilities against running kernel Linux 4.13.0-32-generic #35~16.04.1-Ubuntu SMP Thu Jan 25 10:13:43 UTC 2018 x86_64
CPU is Intel(R) Core(TM) i5-3450 CPU @ 3.10GHz

CVE-2017-5753 [bounds check bypass] aka 'Spectre Variant 1'
* Checking count of LFENCE opcodes in kernel: YES
> STATUS: NOT VULNERABLE (114 opcodes found, which is >= 70, heuristic to be improved when official patches become available)

CVE-2017-5715 [branch target injection] aka 'Spectre Variant 2'
* Mitigation 1
* Hardware (CPU microcode) support for mitigation
* The SPEC_CTRL MSR is available: NO
* The SPEC_CTRL CPUID feature bit is set: NO
* Kernel support for IBRS: YES
* IBRS enabled for Kernel space: NO
* IBRS enabled for User space: NO
* Mitigation 2
* Kernel compiled with retpoline option: NO
* Kernel compiled with a retpoline-aware compiler: NO
> STATUS: VULNERABLE (IBRS hardware + kernel support OR kernel with retpoline are needed to mitigate the vulnerability)

CVE-2017-5754 [rogue data cache load] aka 'Meltdown' aka 'Variant 3'
* Kernel supports Page Table Isolation (PTI): YES
* PTI enabled and active: YES
> STATUS: NOT VULNERABLE (PTI mitigates the vulnerability)

A false sense of security is worse than no security at all, see --disclaimer
 
Hallo

Wird zum aktivieren der Mitigation 1 das für die jeweilig CPU geeignete Microcode Update benötigt, da sonst die entsprechenden Register nicht gelesen werden können?
* The SPEC_CTRL MSR is available: NO
* The SPEC_CTRL CPUID feature bit is set: NO

Ubuntu 16.04.3 LTS , Kernel Linux 4.13.0-32-generic #35~16.04.1-Ubuntu SMP Thu Jan 25 10:13:43 UTC 2018 x86_64
Spectre and Meltdown mitigation detection tool v0.33

Checking for vulnerabilities on current system
Kernel is Linux 4.13.0-32-generic #35~16.04.1-Ubuntu SMP Thu Jan 25 10:13:43 UTC 2018 x86_64
CPU is AMD Ryzen 7 1800X Eight-Core Processor

Hardware check
* Hardware support (CPU microcode) for mitigation techniques
* Indirect Branch Restricted Speculation (IBRS)
* SPEC_CTRL MSR is available: NO
* CPU indicates IBRS capability: NO
* Indirect Branch Prediction Barrier (IBPB)
* PRED_CMD MSR is available: NO
* CPU indicates IBPB capability: NO
* Single Thread Indirect Branch Predictors (STIBP)
* SPEC_CTRL MSR is available: NO
* CPU indicates STIBP capability: NO
* Enhanced IBRS (IBRS_ALL)
* CPU indicates ARCH_CAPABILITIES MSR availability: NO
* ARCH_CAPABILITIES MSR advertises IBRS_ALL capability: NO
* CPU explicitly indicates not being vulnerable to Meltdown (RDCL_NO): NO
* CPU microcode is known to cause stability problems: NO
* CPU vulnerability to the three speculative execution attacks variants
* Vulnerable to Variant 1: YES
* Vulnerable to Variant 2: YES
* Vulnerable to Variant 3: NO

CVE-2017-5753 [bounds check bypass] aka 'Spectre Variant 1'
* Checking count of LFENCE opcodes in kernel: YES
> STATUS: NOT VULNERABLE (114 opcodes found, which is >= 70, heuristic to be improved when official patches become available)

CVE-2017-5715 [branch target injection] aka 'Spectre Variant 2'
* Mitigation 1
* Kernel is compiled with IBRS/IBPB support: YES
* Currently enabled features
* IBRS enabled for Kernel space: NO (echo 1 > /proc/sys/kernel/ibrs_enabled)
* IBRS enabled for User space: NO (echo 2 > /proc/sys/kernel/ibrs_enabled)
* IBPB enabled: NO (echo 1 > /proc/sys/kernel/ibpb_enabled)
* Mitigation 2
* Kernel compiled with retpoline option: NO
* Kernel compiled with a retpoline-aware compiler: NO
* Retpoline enabled: NO
> STATUS: VULNERABLE (IBRS hardware + kernel support OR kernel with retpoline are needed to mitigate the vulnerability)

CVE-2017-5754 [rogue data cache load] aka 'Meltdown' aka 'Variant 3'
* Kernel supports Page Table Isolation (PTI): YES
* PTI enabled and active: NO
* Running as a Xen PV DomU: NO
> STATUS: NOT VULNERABLE (your CPU vendor reported your CPU model as not vulnerable)

A false sense of security is worse than no security at all, see --disclaimer

MfG
RedBaron
 
neue Version 0.34+ sowie das "alte" Microcodeupdate 3.20180108.0+really20170707ubuntu14.04.1
CPU Intel Core i3-540 auf Intel DH55TC, Mint 17.3 mit Kernel 4.4.0-111

Code:
Spectre and Meltdown mitigation detection tool v0.34+

Checking for vulnerabilities on current system
Kernel is Linux 4.4.0-111-generic #134~14.04.1-Ubuntu SMP Mon Jan 15 15:39:56 UTC 2018 x86_64
CPU is Intel(R) Core(TM) i3 CPU         540  @ 3.07GHz

Hardware check
* Hardware support (CPU microcode) for mitigation techniques
  * Indirect Branch Restricted Speculation (IBRS)
    * SPEC_CTRL MSR is available:  NO 
    * CPU indicates IBRS capability:  NO 
  * Indirect Branch Prediction Barrier (IBPB)
    * PRED_CMD MSR is available:  NO 
    * CPU indicates IBPB capability:  NO 
  * Single Thread Indirect Branch Predictors (STIBP)
    * SPEC_CTRL MSR is available:  NO 
    * CPU indicates STIBP capability:  NO 
  * Enhanced IBRS (IBRS_ALL)
    * CPU indicates ARCH_CAPABILITIES MSR availability:  NO 
    * ARCH_CAPABILITIES MSR advertises IBRS_ALL capability:  NO 
  * CPU explicitly indicates not being vulnerable to Meltdown (RDCL_NO):  NO 
  * CPU microcode is known to cause stability problems:  NO  (model 37 stepping 5 ucode 0x4)
* CPU vulnerability to the three speculative execution attacks variants
  * Vulnerable to Variant 1:  YES 
  * Vulnerable to Variant 2:  YES 
  * Vulnerable to Variant 3:  YES 

CVE-2017-5753 [bounds check bypass] aka 'Spectre Variant 1'
* Kernel has array_index_mask_nospec:  NO 
* Checking count of LFENCE instructions following a jump in kernel:  YES  (70 jump-then-lfence instructions found, which is >= 30 (heuristic))
> STATUS:  NOT VULNERABLE  (Kernel source has PROBABLY been patched to mitigate the vulnerability (jump-then-lfence instructions heuristic))

CVE-2017-5715 [branch target injection] aka 'Spectre Variant 2'
* Mitigation 1
  * Kernel is compiled with IBRS/IBPB support:  YES 
  * Currently enabled features
    * IBRS enabled for Kernel space:  NO 
    * IBRS enabled for User space:  NO 
    * IBPB enabled:  NO 
* Mitigation 2
  * Kernel compiled with retpoline option:  NO 
  * Kernel compiled with a retpoline-aware compiler:  NO 
  * Retpoline enabled:  NO 
> STATUS:  VULNERABLE  (IBRS hardware + kernel support OR kernel with retpoline are needed to mitigate the vulnerability)

CVE-2017-5754 [rogue data cache load] aka 'Meltdown' aka 'Variant 3'
* Kernel supports Page Table Isolation (PTI):  YES 
* PTI enabled and active:  YES 
* Running as a Xen PV DomU:  NO 
> STATUS:  NOT VULNERABLE  (PTI mitigates the vulnerability)

A false sense of security is worse than no security at all, see --disclaimer
Tja, nun ist auch Spectre V1 nicht mehr relevant für dieses System.

Wenn ich es richtig verstehe, durch das neue Kernel und nicht durch Microcode gefixt, oder verwechsele ich da was?
 
Zuletzt bearbeitet:
ahh, danke. Also doch wieder durcheinander gekommen.

Mein Laptop hat weiterhin Pech, da nun wirklich alt. Für das was ich mit ihm mache, ist er eigentlich immer noch ausreichend...

CPU Intel Pentium Dual Core T2080 im Toshiba Satelite A200-1CC, Mint 18.3 mit Kernel 4.13 (32bit/i686)

Code:
Spectre and Meltdown mitigation detection tool v0.34+

Checking for vulnerabilities on current system
Kernel is Linux 4.13.0-32-generic #35~16.04.1-Ubuntu SMP Thu Jan 25 10:13:25 UTC 2018 i686
CPU is Genuine Intel(R) CPU           T2080  @ 1.73GHz

Hardware check
* Hardware support (CPU microcode) for mitigation techniques
  * Indirect Branch Restricted Speculation (IBRS)
    * SPEC_CTRL MSR is available:  NO 
    * CPU indicates IBRS capability:  NO 
  * Indirect Branch Prediction Barrier (IBPB)
    * PRED_CMD MSR is available:  NO 
    * CPU indicates IBPB capability:  NO 
  * Single Thread Indirect Branch Predictors (STIBP)
    * SPEC_CTRL MSR is available:  NO 
    * CPU indicates STIBP capability:  NO 
  * Enhanced IBRS (IBRS_ALL)
    * CPU indicates ARCH_CAPABILITIES MSR availability:  NO 
    * ARCH_CAPABILITIES MSR advertises IBRS_ALL capability:  NO 
  * CPU explicitly indicates not being vulnerable to Meltdown (RDCL_NO):  NO 
  * CPU microcode is known to cause stability problems:  NO  (model 14 stepping 12 ucode 0x5b)
* CPU vulnerability to the three speculative execution attacks variants
  * Vulnerable to Variant 1:  YES 
  * Vulnerable to Variant 2:  YES 
  * Vulnerable to Variant 3:  YES 

CVE-2017-5753 [bounds check bypass] aka 'Spectre Variant 1'
* Kernel has array_index_mask_nospec:  NO 
* Checking count of LFENCE instructions following a jump in kernel:  NO  (only 4 jump-then-lfence instructions found, should be >= 30 (heuristic))
> STATUS:  VULNERABLE  (Kernel source needs to be patched to mitigate the vulnerability)

CVE-2017-5715 [branch target injection] aka 'Spectre Variant 2'
* Mitigation 1
  * Kernel is compiled with IBRS/IBPB support:  YES 
  * Currently enabled features
    * IBRS enabled for Kernel space:  NO 
    * IBRS enabled for User space:  NO 
    * IBPB enabled:  NO 
* Mitigation 2
  * Kernel compiled with retpoline option:  NO 
  * Kernel compiled with a retpoline-aware compiler:  NO 
  * Retpoline enabled:  NO 
> STATUS:  VULNERABLE  (IBRS hardware + kernel support OR kernel with retpoline are needed to mitigate the vulnerability)

CVE-2017-5754 [rogue data cache load] aka 'Meltdown' aka 'Variant 3'
* Kernel supports Page Table Isolation (PTI):  NO 
* PTI enabled and active:  NO 
* Running as a Xen PV DomU:  NO 
> STATUS:  VULNERABLE  (PTI is needed to mitigate the vulnerability)

A false sense of security is worse than no security at all, see --disclaimer
 
Zuletzt bearbeitet:
... Mein Laptop hat weiterhin Pech, da nun wirklich alt. Für das was ich mit ihm mache, ist er eigentlich immer noch ausreichend...

CPU Intel Pentium Dual Core T2080 im Toshiba Satelite A200-1CC, Mint 18.3 mit Kernel 4.13 (32bit/i686) ...
Du solltest einen Kernel mit PTI und retpoline verwenden.
 
Du solltest einen Kernel mit PTI und retpoline verwenden.
Zeig mir einen für i686 bzw. 32Bit CPU und ich installiere ihn. Als ich auf den Laptop, das erste mal Linux installieren wollte, habe ich erst mal nicht verstanden warum er die Versionen, die ich hatte, nicht starten wollte. Es ist halt eine alte CPU
 
Zuletzt bearbeitet:
Zeig mir einen für i686 bzw. 32Bit CPU und ich installiere ihn. ...
Falsche Distribution?
Aber Gentoo zu kompilieren würde auf dem Laptop auch keinen Spaß machen ...

Als ich auf den Laptop, das erste mal Linux installieren wollte, habe ich erst mal nicht verstanden warum er die Versionen, die ich hatte, nicht starten wollte. Es ist halt eine alte CPU
Das ist der Nachteil bei Laptops. Bei einem "normalen" PC würde man CPU und Mainboard und vielleicht noch RAM austauschen und weiter geht es.
 
Zuletzt bearbeitet:
Juhu, Spektre1 bin ich nun wohl los, irgendwer hat mir ein paar von diesen opcodes ins System gekippt, nun sind es mehr als 30.

Spectre and Meltdown mitigation detection tool v0.34+

Checking for vulnerabilities on current system
Kernel is Linux 4.13.0-32-generic #35-Ubuntu SMP Thu Jan 25 09:13:46 UTC 2018 x86_64
CPU is AMD Ryzen 7 1700 Eight-Core Processor

Hardware check
* Hardware support (CPU microcode) for mitigation techniques
* Indirect Branch Restricted Speculation (IBRS)
* SPEC_CTRL MSR is available: NO
* CPU indicates IBRS capability: NO
* Indirect Branch Prediction Barrier (IBPB)
* PRED_CMD MSR is available: NO
* CPU indicates IBPB capability: NO
* Single Thread Indirect Branch Predictors (STIBP)
* SPEC_CTRL MSR is available: NO
* CPU indicates STIBP capability: NO
* Enhanced IBRS (IBRS_ALL)
* CPU indicates ARCH_CAPABILITIES MSR availability: NO
* ARCH_CAPABILITIES MSR advertises IBRS_ALL capability: NO
* CPU explicitly indicates not being vulnerable to Meltdown (RDCL_NO): NO
* CPU microcode is known to cause stability problems: NO
* CPU vulnerability to the three speculative execution attacks variants
* Vulnerable to Variant 1: YES
* Vulnerable to Variant 2: YES
* Vulnerable to Variant 3: NO

CVE-2017-5753 [bounds check bypass] aka 'Spectre Variant 1'
* Kernel has array_index_mask_nospec: NO
* Checking count of LFENCE instructions following a jump in kernel: YES (65 jump-then-lfence instructions found, which is >= 30 (heuristic))
> STATUS: NOT VULNERABLE (Kernel source has PROBABLY been patched to mitigate the vulnerability (jump-then-lfence instructions heuristic))

CVE-2017-5715 [branch target injection] aka 'Spectre Variant 2'
* Mitigation 1
* Kernel is compiled with IBRS/IBPB support: YES
* Currently enabled features
* IBRS enabled for Kernel space: NO
* IBRS enabled for User space: NO
* IBPB enabled: NO
* Mitigation 2
* Kernel compiled with retpoline option: NO
* Kernel compiled with a retpoline-aware compiler: NO
* Retpoline enabled: NO
> STATUS: VULNERABLE (IBRS hardware + kernel support OR kernel with retpoline are needed to mitigate the vulnerability)

CVE-2017-5754 [rogue data cache load] aka 'Meltdown' aka 'Variant 3'
* Kernel supports Page Table Isolation (PTI): YES
* PTI enabled and active: NO
* Running as a Xen PV DomU: NO
> STATUS: NOT VULNERABLE (your CPU vendor reported your CPU model as not vulnerable)

A false sense of security is worse than no security at all, see --disclaimer

Nur Spectre2 ist weiterhin aktiv. Auf ein aktuelleres Bios habe ich aber nach wie vor keine Lust.
 
Mit aktualisiertem Kernel:



OS: openSUSE Leap 42.3

Gruß,
Ritschie
 
Zuletzt bearbeitet:
3-mal Not vulnerable.
Wobei das mit Vorsicht zu genießen ist. Bei Spectre 2 fehlt nach wie vor der Fix durch das Microcode-Update für IBRS/IBPB-Support. Wie z.B. hier schön machzulesen ist, handelt es sich also nur um weitere "Flicken", welche das System zwar sicherer, aber nicht komplett sicher machen.

Und um mal kurz den spectre-meltdown-checker zu zitieren: "A false sense of security is worse than no security at all" ;)

Gruß,
Ritschie
 
Die AMD CPUs sind unter Linux im Gegensatz zu den Intel CPUs NICHT auf ein Microcode-Update (softwareseitig oder im bios) angewiesen.
Ein älterer Opteron ist genauso sicher wie die Ryzen.

spectre-meltdown-opti.png


Mit einer Intel CPU älter als Skyline besonders unter Windows ist man wenn Intel und Microsoft weiterhin derartige Schlechtleistungen generieren noch auf Monate oder Jahre angreifbar.
WinTel generiert nur scheinbare Sicherheit und behindert Testalgorithmen mittels MS Defender.
"Unsafe at any speed" titelte Ralph Nader in den 60ern eindringlich und heute auch wieder auf WinTel passend.
Auf solchen Systemen läuft ein Großteil der wichtigen Systeme unserer Weltwirtschaft und vielleicht sind auch deine Kreditkartennummer und Passwordhashes genutzter Zahlungdienstleister auf Seiten der Händler und Dienstleister 'sicher' verwahrt...
 
Die AMD CPUs sind unter Linux im Gegensatz zu den Intel CPUs NICHT auf ein Microcode-Update (softwareseitig oder im bios) angewiesen.
Im Web klingt das aktuell allerdings anders:
Doch während AMDs Microcode-Updates noch auf sich warten lassen, musste Intel seinen ersten Versuch am 22. Januar 2018 zurückziehen, so dass aktuell nur Retpoline übrig ist - allerdings auch nur für Code, der bereits neu compiliert wurde. In einigen Situationen, beispielsweise bei der Virtualisierung, scheint Retpoline jedoch nicht auszureichen, weshalb letztendlich doch Microcode-Updates benötigt werden.
au-ja.de

Klingt für mich so, als ob AMD bei Spectre 2 durchaus noch anfällig wäre (Mitigation 1) *noahnung*

Gruß,
Ritschie
 
Zuletzt bearbeitet:
Ich meinte damit, das es unter Linux für den vergleichsweise sehr kleinen Angriffsvektor auf AMD CPUs Softwarelösungen gibt oder diese in absehbarer Zeit implementiert werden.
Bis alle für den jeweiligen Nutzer relevanten Softwarepakete im Quellcode angepasst und neu kompiliert wurden, kann es dennoch dauern.

Die Ausführung bei au-ja.de ist interessant, geht aber nicht weit genug ins Detail.
Sind da nun nur ungepatchte VMs mit älteren Betriebssystemen gemeint die zudem direkten I/O Zugriff auf Hardware über AMD-Vi (vergleichbar mit Intel VT-d) erhalten, oder weitere Bereiche.



zum Vergleich der aktuelle Stand der Dinge, ebenfalls mit Kernel 4.15 auf Intel Ivy Bridge

spectre-melt-i7qm.png
 
Zuletzt bearbeitet:
Hmm, auf meinem Athlon 5350 mit Kernel 4.14.15 (Arch) ist Spectre 1 noch angreifbar.

 
Was passiert eigentlich, wenn ich meinem 4.4.0-112 (also das aktuelle Ubuntu 16LTS) einen sehr viel aktuelleren Kernel unterjubele?
Funktioniert dann irgendwas nicht mehr ? Sonst hätte Ubuntu das ja sicherlich längst eingebaut.
 
Hmm, auf meinem Athlon 5350 mit Kernel 4.14.15 (Arch) ist Spectre 1 noch angreifbar.


Wenn Du das "msr"-Modul vorher lädst, kann das Script dann auch tatsächlich nachschauen und nicht nur spekulieren ;D
Was aber merkwürdig ist, ist dass ARCH schon längst bei Kernel 4.15 angelangt ist....
Vielleicht benötigst Du nur einen reboot um zum richtigen Kernel zu gelagen, falls Du schon upgegradet hast.
 
Sieht auf einem A4-5000, der nicht so unähnlich dem 5350 ist, unter Arch derzeit so aus:

Screenshot_20180214_070546.png
 
Wenn Du das "msr"-Modul vorher lädst, kann das Script dann auch tatsächlich nachschauen und nicht nur spekulieren ;D
Nochmal hmm: Wie mache ich das? XD Ihr merkt, dass meine Linux Kenntnisse noch in den Kinderschuhen stecken :-/
Was aber merkwürdig ist, ist dass ARCH schon längst bei Kernel 4.15 angelangt ist....
Ich hatte da schlicht seit einigen Tagen nicht geupdatet.

Gestern habe ich dann, wenn ich mich richtig erinnere, Kernel 4.14 aus dem pacman cache nochmal reinstalliert (warum auch immer) und im Anschluss ein komplettes Update durchgeführt. Vor dem Neustart habe ich dann nochmal das Script ausgeführt:



Und nach dem Reboot:



Sieht schon besser aus :)
 
Zuletzt bearbeitet:
OffTopic:

Module Laden, wie das msr, geht zum Beispiel mit
Code:
sudo modprobe msr
 
Zurück
Oben Unten