Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update dependencies; move to @xmldom-scoped is-dom-node package #402

Merged
merged 2 commits into from
Oct 10, 2023
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
change to scoped package
cjbarth committed Oct 10, 2023
commit b0ecaebc2ffbbfa4cafded10a42ef025b93d9ec2
2 changes: 1 addition & 1 deletion src/c14n-canonicalization.ts
Original file line number Diff line number Diff line change
@@ -5,7 +5,7 @@ import type {
RenderedNamespace,
} from "./types";
import * as utils from "./utils";
import * as isDomNode from "is-dom-node";
import * as isDomNode from "@xmldom/is-dom-node";

export class C14nCanonicalization implements CanonicalizationOrTransformationAlgorithm {
includeComments = false;
2 changes: 1 addition & 1 deletion src/enveloped-signature.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import * as xpath from "xpath";
import * as isDomNode from "is-dom-node";
import * as isDomNode from "@xmldom/is-dom-node";

import type {
CanonicalizationOrTransformationAlgorithm,
2 changes: 1 addition & 1 deletion src/exclusive-canonicalization.ts
Original file line number Diff line number Diff line change
@@ -4,7 +4,7 @@ import type {
NamespacePrefix,
} from "./types";
import * as utils from "./utils";
import * as isDomNode from "is-dom-node";
import * as isDomNode from "@xmldom/is-dom-node";

function isPrefixInScope(prefixesInScope, prefix, namespaceURI) {
let ret = false;
2 changes: 1 addition & 1 deletion src/signed-xml.ts
Original file line number Diff line number Diff line change
@@ -23,7 +23,7 @@ import * as envelopedSignatures from "./enveloped-signature";
import * as hashAlgorithms from "./hash-algorithms";
import * as signatureAlgorithms from "./signature-algorithms";
import * as crypto from "crypto";
import * as isDomNode from "is-dom-node";
import * as isDomNode from "@xmldom/is-dom-node";

export class SignedXml {
idMode?: "wssecurity";
2 changes: 1 addition & 1 deletion src/utils.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import * as xpath from "xpath";
import type { NamespacePrefix } from "./types";
import * as isDomNode from "is-dom-node";
import * as isDomNode from "@xmldom/is-dom-node";

export function isArrayHasLength(array: unknown): array is unknown[] {
return Array.isArray(array) && array.length > 0;
2 changes: 1 addition & 1 deletion test/c14n-non-exclusive-unit-tests.spec.ts
Original file line number Diff line number Diff line change
@@ -4,7 +4,7 @@ import { C14nCanonicalization } from "../src/c14n-canonicalization";
import * as xmldom from "@xmldom/xmldom";
import * as xpath from "xpath";
import * as utils from "../src/utils";
import * as isDomNode from "is-dom-node";
import * as isDomNode from "@xmldom/is-dom-node";

const test_C14nCanonicalization = function (xml, xpathArg, expected) {
const doc = new xmldom.DOMParser().parseFromString(xml);
2 changes: 1 addition & 1 deletion test/c14nWithComments-unit-tests.spec.ts
Original file line number Diff line number Diff line change
@@ -4,7 +4,7 @@ import { ExclusiveCanonicalizationWithComments as c14nWithComments } from "../sr
import * as xmldom from "@xmldom/xmldom";
import * as xpath from "xpath";
import { SignedXml } from "../src/index";
import * as isDomNode from "is-dom-node";
import * as isDomNode from "@xmldom/is-dom-node";

const compare = function (xml, xpathArg, expected, inclusiveNamespacesPrefixList?: string[]) {
const doc = new xmldom.DOMParser().parseFromString(xml);
2 changes: 1 addition & 1 deletion test/canonicalization-unit-tests.spec.ts
Original file line number Diff line number Diff line change
@@ -4,7 +4,7 @@ import { ExclusiveCanonicalization } from "../src/exclusive-canonicalization";
import * as xmldom from "@xmldom/xmldom";
import * as xpath from "xpath";
import { SignedXml } from "../src/index";
import * as isDomNode from "is-dom-node";
import * as isDomNode from "@xmldom/is-dom-node";

const compare = function (
xml: string,
2 changes: 1 addition & 1 deletion test/document-tests.spec.ts
Original file line number Diff line number Diff line change
@@ -3,7 +3,7 @@ import * as xpath from "xpath";
import * as xmldom from "@xmldom/xmldom";
import * as fs from "fs";
import { expect } from "chai";
import * as isDomNode from "is-dom-node";
import * as isDomNode from "@xmldom/is-dom-node";

describe("Document tests", function () {
it("test with a document (using FileKeyInfo)", function () {
2 changes: 1 addition & 1 deletion test/hmac-tests.spec.ts
Original file line number Diff line number Diff line change
@@ -3,7 +3,7 @@ import * as xpath from "xpath";
import * as xmldom from "@xmldom/xmldom";
import * as fs from "fs";
import { expect } from "chai";
import * as isDomNode from "is-dom-node";
import * as isDomNode from "@xmldom/is-dom-node";

describe("HMAC tests", function () {
it("test validating HMAC signature", function () {
2 changes: 1 addition & 1 deletion test/key-info-tests.spec.ts
Original file line number Diff line number Diff line change
@@ -3,7 +3,7 @@ import * as fs from "fs";
import * as xpath from "xpath";
import { SignedXml } from "../src/index";
import { expect } from "chai";
import * as isDomNode from "is-dom-node";
import * as isDomNode from "@xmldom/is-dom-node";

describe("KeyInfo tests", function () {
it("adds X509Certificate element during signature", function () {
2 changes: 1 addition & 1 deletion test/saml-response-tests.spec.ts
Original file line number Diff line number Diff line change
@@ -3,7 +3,7 @@ import * as xpath from "xpath";
import * as xmldom from "@xmldom/xmldom";
import * as fs from "fs";
import { expect } from "chai";
import * as isDomNode from "is-dom-node";
import * as isDomNode from "@xmldom/is-dom-node";

describe("SAML response tests", function () {
it("test validating SAML response", function () {
2 changes: 1 addition & 1 deletion test/signature-integration-tests.spec.ts
Original file line number Diff line number Diff line change
@@ -3,7 +3,7 @@ import * as xmldom from "@xmldom/xmldom";
import { SignedXml } from "../src/index";
import * as fs from "fs";
import { expect } from "chai";
import * as isDomNode from "is-dom-node";
import * as isDomNode from "@xmldom/is-dom-node";

describe("Signature integration tests", function () {
function verifySignature(xml, expected, xpath) {
2 changes: 1 addition & 1 deletion test/signature-unit-tests.spec.ts
Original file line number Diff line number Diff line change
@@ -4,7 +4,7 @@ import { SignedXml, createOptionalCallbackFunction } from "../src/index";
import * as fs from "fs";
import * as crypto from "crypto";
import { expect } from "chai";
import * as isDomNode from "is-dom-node";
import * as isDomNode from "@xmldom/is-dom-node";

describe("Signature unit tests", function () {
function verifySignature(xml: string, idMode?: "wssecurity") {
2 changes: 1 addition & 1 deletion test/wsfed-metadata-tests.spec.ts
Original file line number Diff line number Diff line change
@@ -3,7 +3,7 @@ import * as xpath from "xpath";
import * as xmldom from "@xmldom/xmldom";
import * as fs from "fs";
import { expect } from "chai";
import * as isDomNode from "is-dom-node";
import * as isDomNode from "@xmldom/is-dom-node";

describe("WS-Fed Metadata tests", function () {
it("test validating WS-Fed Metadata", function () {