Gathering detailed insights and metrics for detect-libc
Gathering detailed insights and metrics for detect-libc
Gathering detailed insights and metrics for detect-libc
Gathering detailed insights and metrics for detect-libc
@types/detect-libc
TypeScript definitions for detect-libc
tell-libc
Detect libc (glibc/musl) for Node.js
@ameerarsala/detect-libc
Node.js module to detect the C standard library (libc) implementation family and version
xxxdetect-libc
Node.js module to detect the C standard library (libc) implementation family and version
Node.js module to detect details of the C standard library (libc) implementation provided by a given Linux system
npm install detect-libc
Typescript
Module System
Min. Node Version
Node Version
NPM Version
JavaScript (100%)
Total Downloads
0
Last Day
0
Last Week
0
Last Month
0
Last Year
0
Apache-2.0 License
66 Stars
60 Commits
13 Forks
2 Watchers
2 Branches
7 Contributors
Updated on May 08, 2025
Latest Version
2.0.4
Package Id
detect-libc@2.0.4
Unpacked Size
23.10 kB
Size
6.94 kB
File Count
7
NPM Version
10.9.2
Node Version
22.14.0
Published on
Apr 22, 2025
Cumulative downloads
Total Downloads
Last Day
0%
NaN
Compared to previous day
Last Week
0%
NaN
Compared to previous week
Last Month
0%
NaN
Compared to previous month
Last Year
0%
NaN
Compared to previous year
5
Node.js module to detect details of the C standard library (libc) implementation provided by a given Linux system.
Currently supports detection of GNU glibc and MUSL libc.
Provides asychronous and synchronous functions for the
family (e.g. glibc
, musl
) and version (e.g. 1.23
, 1.2.3
).
The version numbers of libc implementations are not guaranteed to be semver-compliant.
For previous v1.x releases, please see the v1 branch.
1npm install detect-libc
1const GLIBC: string = 'glibc';
A String constant containing the value glibc
.
1const MUSL: string = 'musl';
A String constant containing the value musl
.
1function family(): Promise<string | null>;
Resolves asychronously with:
glibc
or musl
when the libc family can be determinednull
when the libc family cannot be determinednull
when run on a non-Linux platform1const { family, GLIBC, MUSL } = require('detect-libc'); 2 3switch (await family()) { 4 case GLIBC: ... 5 case MUSL: ... 6 case null: ... 7}
1function familySync(): string | null;
Synchronous version of family()
.
1const { familySync, GLIBC, MUSL } = require('detect-libc'); 2 3switch (familySync()) { 4 case GLIBC: ... 5 case MUSL: ... 6 case null: ... 7}
1function version(): Promise<string | null>;
Resolves asychronously with:
null
when the libc family cannot be determinednull
when run on a non-Linux platform1const { version } = require('detect-libc'); 2 3const v = await version(); 4if (v) { 5 const [major, minor, patch] = v.split('.'); 6}
1function versionSync(): string | null;
Synchronous version of version()
.
1const { versionSync } = require('detect-libc'); 2 3const v = versionSync(); 4if (v) { 5 const [major, minor, patch] = v.split('.'); 6}
1function isNonGlibcLinux(): Promise<boolean>;
Resolves asychronously with:
false
when the libc family is glibc
true
when the libc family is not glibc
false
when run on a non-Linux platform1const { isNonGlibcLinux } = require('detect-libc'); 2 3if (await isNonGlibcLinux()) { ... }
1function isNonGlibcLinuxSync(): boolean;
Synchronous version of isNonGlibcLinux()
.
1const { isNonGlibcLinuxSync } = require('detect-libc'); 2 3if (isNonGlibcLinuxSync()) { ... }
Copyright 2017 Lovell Fuller and others.
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
No vulnerabilities found.
Reason
no binaries found in the repo
Reason
no dangerous workflow patterns detected
Reason
license file detected
Details
Reason
0 existing vulnerabilities detected
Reason
4 commit(s) and 1 issue activity found in the last 90 days -- score normalized to 4
Reason
Found 7/30 approved changesets -- score normalized to 2
Reason
dependency not pinned by hash detected -- score normalized to 0
Details
Reason
detected GitHub workflow tokens with excessive permissions
Details
Reason
no effort to earn an OpenSSF best practices badge detected
Reason
project is not fuzzed
Details
Reason
security policy file not detected
Details
Reason
branch protection not enabled on development/release branches
Details
Reason
SAST tool is not run on all commits -- score normalized to 0
Details
Score
Last Scanned on 2025-07-07
The Open Source Security Foundation is a cross-industry collaboration to improve the security of open source software (OSS). The Scorecard provides security health metrics for open source projects.
Learn More