Security News
Research
Data Theft Repackaged: A Case Study in Malicious Wrapper Packages on npm
The Socket Research Team breaks down a malicious wrapper package that uses obfuscation to harvest credentials and exfiltrate sensitive data.
############################## Collect information on x86 CPU ##############################
Uses cpuid <https://en.wikipedia.org/wiki/CPUID>
_ instruction to get
information about CPU.
Queries OS as well as cpuid <https://en.wikipedia.org/wiki/Advanced_Vector_Extensions#Operating_system_support>
_
to see if the OS / CPU supports AVX instructions.
Quickstart
from x86cpu import info print(info.model_display, info.family_display) (69, 6) print(info.vendor) GenuineIntel print(info.brand) 'Intel(R) Core(TM) i5-4250U CPU @ 1.30GHz'
You can run the cpuid
command directly. The argument to cpuid
goes
into the EAX
register before calling the CPUID instruction:
from x86cpu import cpuid cpuid(1) {'eax': 263761L, 'ebx': 17827840L, 'ecx': 2147154879L, 'edx': 3219913727L}
Some CPUID commands also care about the value in the ECX
register. You
can set this with a second optional argument to cpuid
:
cpuid(13, 1) {'eax': 1, 'ebx': 0, 'ecx': 0, 'edx': 0}
The package installs a command line tool x86report
giving output like
this::
$ x86report
x86cpu report
-------------
brand : Intel(R) Core(TM) i5-4250U CPU @ 1.30GHz
vendor : GenuineIntel
model (display) : 69
family (display) : 6
model : 5
family : 6
extended model : 4
extended family : 0
stepping : 1
processor type : 0
signature : 263761
MMX : True
3DNow! : True
SSE : True
SSE2 : True
SSE3 : True
SSSE3 : True
SSE4.1 : True
SSE4.2 : True
supports AVX : True
supports AVX2 : True
Code
See https://github.com/matthew-brett/x86cpu
Released under the BSD two-clause license - see the file LICENSE
in the
source distribution.
The latest released version is at https://pypi.python.org/pypi/x86cpu
Support
Please put up issues on the x86cpu issue tracker <https://github.com/matthew-brett/x86cpu/issues>
_.
FAQs
Collect information about x86 CPU
We found that x86cpu demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Research
The Socket Research Team breaks down a malicious wrapper package that uses obfuscation to harvest credentials and exfiltrate sensitive data.
Research
Security News
Attackers used a malicious npm package typosquatting a popular ESLint plugin to steal sensitive data, execute commands, and exploit developer systems.
Security News
The Ultralytics' PyPI Package was compromised four times in one weekend through GitHub Actions cache poisoning and failure to rotate previously compromised API tokens.