export function validateBase64(s) {
if (!/^(?:[A-Za-z0-9+/]{4})*(?:[A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=)?$/.test(s)) {
throw new TypeError('invalid base64 string');
}
}
export function validateHex(s) {
if (!/^(?:[A-Fa-f0-9]{2})+$/.test(s)) {
throw new TypeError('invalid hex string');
}
}
//# sourceMappingURL=validate.js.map