systeminformation 5.26.0 → 5.26.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/lib/graphics.js CHANGED
@@ -425,7 +425,8 @@ function graphics(callback) {
425
425
  options.stdio = ['pipe', 'pipe', 'ignore'];
426
426
  }
427
427
  try {
428
- const res = execSync(cmd, options).toString();
428
+ const sanitized = util.sanitizeShellString(cmd);
429
+ const res = execSync(sanitized, options).toString();
429
430
  return res;
430
431
  } catch (e) {
431
432
  util.noop();
package/lib/index.d.ts CHANGED
@@ -991,8 +991,11 @@ export function diskLayout(cb?: (data: Systeminformation.DiskLayoutData[]) => an
991
991
 
992
992
  export function networkInterfaceDefault(cb?: (data: string) => any): Promise<string>;
993
993
  export function networkGatewayDefault(cb?: (data: string) => any): Promise<string>;
994
+ export function networkInterfaces(): Promise<Systeminformation.NetworkInterfacesData[]>;
995
+ export function networkInterfaces(defaultString: 'default'): Promise<Systeminformation.NetworkInterfacesData>;
996
+ export function networkInterfaces(rescan: boolean): Promise<Systeminformation.NetworkInterfacesData[]>;
994
997
  export function networkInterfaces(
995
- cb?:
998
+ cb:
996
999
  | ((data: Systeminformation.NetworkInterfacesData[] | Systeminformation.NetworkInterfacesData) => any)
997
1000
  | boolean
998
1001
  | string,
package/lib/util.js CHANGED
@@ -2538,7 +2538,7 @@ function checkWebsite(url, timeout = 5000) {
2538
2538
  });
2539
2539
  })
2540
2540
  .setTimeout(timeout, () => {
2541
- request.close();
2541
+ request.destroy();
2542
2542
  resolve({
2543
2543
  url,
2544
2544
  statusCode: 408,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "systeminformation",
3
- "version": "5.26.0",
3
+ "version": "5.26.1",
4
4
  "description": "Advanced, lightweight system and OS information library",
5
5
  "license": "MIT",
6
6
  "author": "Sebastian Hildebrandt <hildebrandt@plus-innovations.com> (https://plus-innovations.com)",