"use strict";
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT license.
// Generated from ../../../cs/src/Contracts/TunnelConstraints.cs
/* eslint-disable */
Object.defineProperty(exports, "__esModule", { value: true });
exports.TunnelConstraints = void 0;
/**
 * Tunnel constraints.
 */
var TunnelConstraints;
(function (TunnelConstraints) {
    /**
     * Min length of tunnel cluster ID.
     */
    TunnelConstraints.clusterIdMinLength = 3;
    /**
     * Max length of tunnel cluster ID.
     */
    TunnelConstraints.clusterIdMaxLength = 12;
    /**
     * Length of V1 tunnel id.
     */
    TunnelConstraints.oldTunnelIdLength = 8;
    /**
     * Min length of V2 tunnelId.
     */
    TunnelConstraints.newTunnelIdMinLength = 3;
    /**
     * Max length of V2 tunnelId.
     *
     * Limited to 49 characters to ensure tunnel URIs with ports and inspection suffixes
     * (-&lt;port&gt;-inspect) remain within the DNS label limit of 63 characters.
     */
    TunnelConstraints.newTunnelIdMaxLength = 49;
    /**
     * Length of a tunnel alias.
     */
    TunnelConstraints.tunnelAliasLength = 8;
    /**
     * Min length of tunnel name.
     */
    TunnelConstraints.tunnelNameMinLength = 3;
    /**
     * Max length of tunnel name.
     *
     * Limited to 49 characters to ensure tunnel URIs with ports and inspection suffixes
     * (-&lt;port&gt;-inspect) remain within the DNS label limit of 63 characters.
     */
    TunnelConstraints.tunnelNameMaxLength = 49;
    /**
     * Max length of SSH username.
     */
    TunnelConstraints.sshUserMaxLength = 60;
    /**
     * Max length of tunnel or port description.
     */
    TunnelConstraints.descriptionMaxLength = 400;
    /**
     * Max length of tunnel event details.
     */
    TunnelConstraints.eventDetailsMaxLength = 4000;
    /**
     * Max number of properties in a tunnel event.
     */
    TunnelConstraints.maxEventProperties = 100;
    /**
     * Max length of a single tunnel event property value.
     */
    TunnelConstraints.eventPropertyValueMaxLength = 4000;
    /**
     * Min length of a single tunnel or port tag.
     */
    TunnelConstraints.labelMinLength = 1;
    /**
     * Max length of a single tunnel or port tag.
     */
    TunnelConstraints.labelMaxLength = 50;
    /**
     * Maximum number of labels that can be applied to a tunnel or port.
     */
    TunnelConstraints.maxLabels = 100;
    /**
     * Min length of a tunnel domain.
     */
    TunnelConstraints.tunnelDomainMinLength = 4;
    /**
     * Max length of a tunnel domain.
     */
    TunnelConstraints.tunnelDomainMaxLength = 180;
    /**
     * Maximum number of items allowed in the tunnel ports array. The actual limit on
     * number of ports that can be created may be much lower, and may depend on various
     * resource limitations or policies.
     */
    TunnelConstraints.tunnelMaxPorts = 1000;
    /**
     * Maximum number of access control entries (ACEs) in a tunnel or tunnel port access
     * control list (ACL).
     */
    TunnelConstraints.accessControlMaxEntries = 40;
    /**
     * Maximum number of subjects (such as user IDs) in a tunnel or tunnel port access
     * control entry (ACE).
     */
    TunnelConstraints.accessControlMaxSubjects = 100;
    /**
     * Max length of an access control subject or organization ID.
     */
    TunnelConstraints.accessControlSubjectMaxLength = 200;
    /**
     * Max length of an access control subject name, when resolving names to IDs.
     */
    TunnelConstraints.accessControlSubjectNameMaxLength = 200;
    /**
     * Maximum number of scopes in an access control entry.
     */
    TunnelConstraints.accessControlMaxScopes = 10;
    /**
     * Regular expression that can match or validate tunnel event name strings.
     */
    TunnelConstraints.eventNamePattern = '^[a-z0-9_]{3,80}$';
    /**
     * Regular expression that can match or validate tunnel event severity strings.
     */
    TunnelConstraints.eventSeverityPattern = '^(info)|(warning)|(error)$';
    /**
     * Regular expression that can match or validate tunnel event property name strings.
     */
    TunnelConstraints.eventPropertyNamePattern = '^[a-zA-Z0-9_.]{3,200}$';
    /**
     * Regular expression that can match or validate tunnel cluster ID strings.
     *
     * Cluster IDs are alphanumeric; hyphens are not permitted.
     */
    TunnelConstraints.clusterIdPattern = '^(([a-z]{3,4}[0-9]{1,3})|asse|aue|brs|euw|use)$';
    /**
     * Regular expression that can match or validate tunnel cluster ID strings.
     *
     * Cluster IDs are alphanumeric; hyphens are not permitted.
     */
    TunnelConstraints.clusterIdRegex = new RegExp(TunnelConstraints.clusterIdPattern);
    /**
     * Regular expression that can match or validate a tunnel cluster ID as a hostname
     * prefix.
     *
     * Cluster IDs are alphanumeric; hyphens are not permitted.
     */
    TunnelConstraints.clusterIdPrefixRegex = new RegExp(TunnelConstraints.clusterIdPattern.replace('$', '\\.'));
    /**
     * Characters that are valid in tunnel IDs. Includes numbers and lowercase letters,
     * excluding vowels and 'y' (to avoid accidentally generating any random words).
     */
    TunnelConstraints.oldTunnelIdChars = '0123456789bcdfghjklmnpqrstvwxz';
    /**
     * Regular expression that can match or validate tunnel ID strings.
     *
     * Tunnel IDs are fixed-length and have a limited character set of numbers and
     * lowercase letters (minus vowels and y).
     */
    TunnelConstraints.oldTunnelIdPattern = '[' + TunnelConstraints.oldTunnelIdChars + ']{8}';
    /**
     * Regular expression that can match or validate tunnel ID strings.
     *
     * Tunnel IDs are fixed-length and have a limited character set of numbers and
     * lowercase letters (minus vowels and y).
     */
    TunnelConstraints.oldTunnelIdRegex = new RegExp(TunnelConstraints.oldTunnelIdPattern);
    /**
     * Characters that are valid in tunnel IDs. Includes numbers and lowercase letters,
     * excluding vowels and 'y' (to avoid accidentally generating any random words).
     */
    TunnelConstraints.newTunnelIdChars = '0123456789abcdefghijklmnopqrstuvwxyz-';
    /**
     * Regular expression that can match or validate tunnel ID strings.
     *
     * Tunnel IDs have a limited character set of numbers and lowercase letters. Limited
     * to 49 characters to ensure tunnel URIs with ports and inspection suffixes remain
     * within the DNS label limit of 63 characters.
     */
    TunnelConstraints.newTunnelIdPattern = '[a-z0-9][a-z0-9-]{1,47}[a-z0-9]';
    /**
     * Regular expression that can match or validate tunnel ID strings.
     *
     * Tunnel IDs are fixed-length and have a limited character set of numbers and
     * lowercase letters (minus vowels and y).
     */
    TunnelConstraints.newTunnelIdRegex = new RegExp(TunnelConstraints.newTunnelIdPattern);
    /**
     * Characters that are valid in tunnel IDs. Includes numbers and lowercase letters,
     * excluding vowels and 'y' (to avoid accidentally generating any random words).
     */
    TunnelConstraints.tunnelAliasChars = '0123456789bcdfghjklmnpqrstvwxz';
    /**
     * Regular expression that can match or validate tunnel alias strings.
     *
     * Tunnel Aliases are fixed-length and have a limited character set of numbers and
     * lowercase letters (minus vowels and y). Limited to 49 characters to ensure tunnel
     * URIs with ports and inspection suffixes remain within the DNS label limit of 63
     * characters.
     */
    TunnelConstraints.tunnelAliasPattern = '[' + TunnelConstraints.tunnelAliasChars + ']{3,49}';
    /**
     * Regular expression that can match or validate tunnel alias strings.
     *
     * Tunnel Aliases are fixed-length and have a limited character set of numbers and
     * lowercase letters (minus vowels and y).
     */
    TunnelConstraints.tunnelAliasRegex = new RegExp(TunnelConstraints.tunnelAliasPattern);
    /**
     * Regular expression that can match or validate tunnel names.
     *
     * Tunnel names are alphanumeric and may contain hyphens. The pattern also allows an
     * empty string because tunnels may be unnamed. Limited to 49 characters to ensure
     * tunnel URIs with ports and inspection suffixes remain within the DNS label limit of
     * 63 characters.
     */
    TunnelConstraints.tunnelNamePattern = '([a-z0-9][a-z0-9-]{1,47}[a-z0-9])|(^$)';
    /**
     * Regular expression that can match or validate tunnel names.
     *
     * Tunnel names are alphanumeric and may contain hyphens. The pattern also allows an
     * empty string because tunnels may be unnamed.
     */
    TunnelConstraints.tunnelNameRegex = new RegExp(TunnelConstraints.tunnelNamePattern);
    /**
     * Regular expression that can match or validate tunnel or port labels.
     */
    TunnelConstraints.labelPattern = '[\\w-=]{1,50}';
    /**
     * Regular expression that can match or validate tunnel or port labels.
     */
    TunnelConstraints.labelRegex = new RegExp(TunnelConstraints.labelPattern);
    /**
     * Regular expression that can match or validate tunnel domains.
     *
     * The tunnel service may perform additional contextual validation at the time the
     * domain is registered.
     */
    TunnelConstraints.tunnelDomainPattern = '[0-9a-z][0-9a-z-.]{1,158}[0-9a-z]|(^$)';
    /**
     * Regular expression that can match or validate tunnel domains.
     *
     * The tunnel service may perform additional contextual validation at the time the
     * domain is registered.
     */
    TunnelConstraints.tunnelDomainRegex = new RegExp(TunnelConstraints.tunnelDomainPattern);
    /**
     * Regular expression that can match or validate an access control subject or
     * organization ID.
     *
     * The : and / characters are allowed because subjects may include IP addresses and
     * ranges. The @ character is allowed because MSA subjects may be identified by email
     * address.
     */
    TunnelConstraints.accessControlSubjectPattern = '[0-9a-zA-Z-._:/@]{0,200}';
    /**
     * Regular expression that can match or validate an access control subject or
     * organization ID.
     */
    TunnelConstraints.accessControlSubjectRegex = new RegExp(TunnelConstraints.accessControlSubjectPattern);
    /**
     * Regular expression that can match or validate an access control subject name, when
     * resolving subject names to IDs.
     *
     * Note angle-brackets are only allowed when they wrap an email address as part of a
     * formatted name with email. The service will block any other use of angle-brackets,
     * to avoid any XSS risks.
     */
    TunnelConstraints.accessControlSubjectNamePattern = '[ \\w\\d-.,/:\'"_@()<>]{0,200}';
    /**
     * Regular expression that can match or validate an access control subject name, when
     * resolving subject names to IDs.
     */
    TunnelConstraints.accessControlSubjectNameRegex = new RegExp(TunnelConstraints.accessControlSubjectNamePattern);
})(TunnelConstraints = exports.TunnelConstraints || (exports.TunnelConstraints = {}));
//# sourceMappingURL=https://github.com/VSCodium/sourcemaps/releases/download/stable-824c4c46a288b839f13b24022655329c2aeb9f81/node_modules-@microsoft-dev-tunnels-contracts-tunnelConstraints.js.map