Source: blog. csdn. netdba_huangzjarticledetails38489765, topic Directory: blog. csdn. netdba_huangzjarticledetails37906349 no one shall publish in the original form or use it for commercial purposes without the consent of the author. I am not responsible for any legal liability. Previous Article: B
Source of the original article: without the consent of the author, no one shall publish in the original form or use it for commercial purposes. I am not responsible for any legal liability. Previous Article: http: // B
Source: Workshop
Without the consent of the author, no one shall be published in the form of "original" or used for commercial purposes. I am not responsible for any legal liability.
Previous Article: http://blog.csdn.net/dba_huangzj/article/details/38438363
Preface:
An SQL Server Endpoint is a portal for accessing and exiting SQL Server. Through an Endpoint, everything can be transmitted between the network and SQL Server. An endpoint can be either a system or user-defined, where the system endpoint allows the T-SQL to connect to the SQL Server and send queries.
The endpoint uses a specific protocol definition, which can be HTTP or TCP. Starting from SQL Server 2012, the HTTP endpoint is removed from the built-in Web Services function and can only use the TCP endpoint.
Generally, custom endpoints are used for the following purposes:
TCP request. This article describes how to establish a dedicated or secure SQL Server connection. Service Broker database image implementation:
1. Enter the following statement in the query window:
CREATE ENDPOINT myTSQLEndpoint STATE = started AS TCP ( LISTENER_PORT = 8080, LISTENER_IP = (127.0.0.1) ) FOR TSQL ();
2. After the execution, you will receive the following message, which means that all logins connected through the default T-SQL endpoint will lose all permissions, you need to use the following statement authorization:
GRANT CONNECT ON ENDPOINT::[TSQL Default TCP] to [public];
Message:
Creating a TSQL endpoint will result in revoking all 'public' connection permissions on the 'tsql Default TCP 'endpoint. If the 'public' access permission is required ON this end point, use 'Grant connect on endpoint: [TSQL Default TCP] to [Public] 'to re-apply this permission.
3. You can use the following statement to query the endpoint information:
SELECT * FROM sys.tcp_endpoints;
4. You can use the alter endpoint command to start or stop an ENDPOINT:
ALTER ENDPOINT [TSQL Default TCP] STATE = STOPPED;
Principle:
After SQL Server is installed, the corresponding SQL Server System endpoint is created for each network protocol. The access endpoint permission is granted to the Public server role. Each SQL Server logon has the Public role permission. You can use the following statement to authorize and revoke permissions:
REVOKE CONNECT ON ENDPOINT::[TSQL Default TCP] to [public]; GRANT CONNECT ON ENDPOINT::[TSQL Default TCP] to [a_specific_login];