/// <summary>
        /// Constructor.
        /// </summary>
        /// <param name="port">The port to be connected</param>
        public AdtsLdapServer(ushort port, AdtsLdapConnectionType connectionType)
        {
            this.listenPort = port;
            if (connectionType == AdtsLdapConnectionType.Tcp
                || connectionType == AdtsLdapConnectionType.TlsOrSsl)
            {
                this.isTcp = true;
            }
            else
            {
                this.isTcp = false;
            }

            this.encoderv2 = new AdtsLdapV2Encoder();
            this.encoderv3 = new AdtsLdapV3Encoder();
            this.contextManager = new AdtsLdapContextManager();
            this.decoder = new AdtsLdapServerDecoder(this);
        }
Esempio n. 2
0
        /// <summary>
        /// Constructor.
        /// </summary>
        /// <param name="port">The port to be connected</param>
        public AdtsLdapServer(ushort port, AdtsLdapConnectionType connectionType)
        {
            this.listenPort = port;
            if (connectionType == AdtsLdapConnectionType.Tcp ||
                connectionType == AdtsLdapConnectionType.TlsOrSsl)
            {
                this.isTcp = true;
            }
            else
            {
                this.isTcp = false;
            }

            this.encoderv2      = new AdtsLdapV2Encoder();
            this.encoderv3      = new AdtsLdapV3Encoder();
            this.contextManager = new AdtsLdapContextManager();
            this.decoder        = new AdtsLdapServerDecoder(this);
        }