Oracel增加IP白名单限制
F:\Java\Oracle\product\11.2.0\dbhome_1\NETWORK\ADMIN\sqlnet.ora
修改sqlnet.ora文件增加两行
# like12 add,20231025,IP白名单限制
TCP.VALIDNODE_CHECKING=yes
TCP.INVITED_NODES=(WIN-I4HJRGH080V,127.0.0.1,xxx.xxx.xxx.xxx)
注意:需要将计算机名hostname添加进去 否则本机PL/SQL工具连接不了
完整示例为:
# sqlnet.ora Network Configuration File: F:\Java\Oracle\product\11.2.0\dbhome_1\network\admin\sqlnet.ora
# Generated by Oracle configuration tools.
# This file is actually generated by netca. But if customers choose to
# install "Software Only", this file wont exist and without the native
# authentication, they will not be able to connect to the database on NT.
SQLNET.AUTHENTICATION_SERVICES= (NTS)
NAMES.DIRECTORY_PATH= (TNSNAMES, EZCONNECT)
# like12 add,20231025,IP白名单限制
TCP.VALIDNODE_CHECKING=yes
TCP.INVITED_NODES=(WIN-I4HJRGH080V,127.0.0.1,58.42.241.105)
可能不需要的操作:
修改listener.ora文件 增加一段
# like12 add,20231025,IP白名单限制
(SID_DESC =
(GLOBAL_NAME = orcl)
(ORACLE_HOME = F:\Java\Oracle\product\11.2.0\dbhome_1)
(SID_NAME = orcl)
)
完整示例为:
# listener.ora Network Configuration File: F:\Java\Oracle\product\11.2.0\dbhome_1\network\admin\listener.ora
# Generated by Oracle configuration tools.
SID_LIST_LISTENER =
(SID_LIST =
(SID_DESC =
(SID_NAME = CLRExtProc)
(ORACLE_HOME = F:\Java\Oracle\product\11.2.0\dbhome_1)
(PROGRAM = extproc)
(ENVS = "EXTPROC_DLLS=ONLY:F:\Java\Oracle\product\11.2.0\dbhome_1\bin\oraclr11.dll")
)
# like12 add,20231025,IP白名单限制
(SID_DESC =
(GLOBAL_NAME = orcl)
(ORACLE_HOME = F:\Java\Oracle\product\11.2.0\dbhome_1)
(SID_NAME = orcl)
)
)
LISTENER =
(DESCRIPTION_LIST =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1521))
(ADDRESS = (PROTOCOL = TCP)(HOST = WIN-I4HJRGH080V)(PORT = 1521))
)
)
ADR_BASE_LISTENER = F:\Java\Oracle