Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
// tslint:disable:no-console
import * as chalk from "chalk";
import { EventEmitter } from "events";
import { assert } from "node-opcua-assert";
import { display_trace_from_this_projet_only, hexDump, make_debugLog } from "node-opcua-debug";
import { analyseExtensionObject } from "node-opcua-packet-analyzer";
import { GetEndpointsResponse } from "node-opcua-service-endpoints";
import { CloseSecureChannelResponse, OpenSecureChannelResponse } from "node-opcua-service-secure-channel";
import { ActivateSessionResponse, CreateSessionResponse } from "node-opcua-service-session";
import { AcknowledgeMessage } from "node-opcua-transport";
import { DirectTransport } from "node-opcua-transport/dist/test_helpers";
import * as _ from "underscore";
const debugLog = make_debugLog(__filename);
export const fakeAcknowledgeMessage = new AcknowledgeMessage({
maxChunkCount: 600000,
maxMessageSize: 100000,
protocolVersion: 0,
receiveBufferSize: 8192,
sendBufferSize: 8192,
});
export const fakeCloseSecureChannelResponse = new CloseSecureChannelResponse({});
export const fakeOpenSecureChannelResponse = new OpenSecureChannelResponse({
serverProtocolVersion: 0,
securityToken: {
channelId: 23,
createdAt: new Date(), // now
revisedLifetime: 30000,