{"id":15489321,"url":"https://github.com/streamich/cpuid","last_synced_at":"2025-10-28T00:31:11.066Z","repository":{"id":50413671,"uuid":"60965093","full_name":"streamich/cpuid","owner":"streamich","description":"cpuid x86 in JavaScript","archived":false,"fork":false,"pushed_at":"2021-01-06T20:55:38.000Z","size":9,"stargazers_count":3,"open_issues_count":3,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2024-11-15T10:57:23.180Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/streamich.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2016-06-12T12:03:44.000Z","updated_at":"2024-08-20T21:06:36.000Z","dependencies_parsed_at":"2022-09-24T10:45:24.197Z","dependency_job_id":null,"html_url":"https://github.com/streamich/cpuid","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/streamich%2Fcpuid","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/streamich%2Fcpuid/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/streamich%2Fcpuid/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/streamich%2Fcpuid/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/streamich","download_url":"https://codeload.github.com/streamich/cpuid/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":238574788,"owners_count":19494724,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-10-02T07:05:00.152Z","updated_at":"2025-10-28T00:31:05.795Z","avatar_url":"https://github.com/streamich.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# cpuid\r\n\r\nExecute any x86 `cpuid` call. You pass two arguments: `eax` and `ecx` register values and get back a response\r\nof 4 numbers in an array, the response returned as an array `[eax, ebx, edx, ecx]`.\r\n\r\nExample, when you execute `0, 0` call Intel returns `GenuineIntel` string\r\nin last three registers:\r\n\r\n```js\r\nvar cpuid = require('cpuid');\r\nvar temp = cpuid(0, 0);\r\nconsole.log(temp); // [ 13, 1970169159, 1231384169, 1818588270 ]\r\n```\r\n\r\nNow let's create a string out of that:\r\n\r\n```js\r\nvar str = '';\r\nfor(var i = 1; i \u003c temp.length; i++) {\r\n    var reg = temp[i];\r\n    str += String.fromCharCode(reg \u0026 0xFF);\r\n    str += String.fromCharCode((reg \u003e\u003e 8) \u0026 0xFF);\r\n    str += String.fromCharCode((reg \u003e\u003e 16) \u0026 0xFF);\r\n    str += String.fromCharCode((reg \u003e\u003e 24) \u0026 0xFF);\r\n}\r\nconsole.log(str); // GenuineIntel\r\n```\r\n\r\nIf you run under some virtual machine, those usually use `0x40000000` address\r\nto return their name:\r\n\r\n```js\r\ntemp = cpuid(0x40000000, 0);\r\nvar str = '';\r\nfor(var i = 0; i \u003c temp.length; i++) {\r\n    var reg = temp[i];\r\n    str += String.fromCharCode(reg \u0026 0xFF);\r\n    str += String.fromCharCode((reg \u003e\u003e 8) \u0026 0xFF);\r\n    str += String.fromCharCode((reg \u003e\u003e 16) \u0026 0xFF);\r\n    str += String.fromCharCode((reg \u003e\u003e 24) \u0026 0xFF);\r\n}\r\nconsole.log(str); // @VBoxVBoxVBox\r\n```\r\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fstreamich%2Fcpuid","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fstreamich%2Fcpuid","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fstreamich%2Fcpuid/lists"}