13 lines
511 B
TypeScript
13 lines
511 B
TypeScript
import { Readable } from 'node:stream';
|
|
/**
|
|
* Verify the passed in xml is valid. Requires xmllib be installed
|
|
*
|
|
* Security: This function always pipes XML content via stdin to prevent
|
|
* command injection vulnerabilities. Never pass user-controlled strings
|
|
* as file path arguments to xmllint.
|
|
*
|
|
* @param xml what you want validated (string or Readable stream)
|
|
* @return {Promise<void>} resolves on valid rejects [error stderr]
|
|
*/
|
|
export declare function xmlLint(xml: string | Readable): Promise<void>;
|