Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

How to perform ORACLE database connection and login verification

2025-04-02 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >

Share

Shulou(Shulou.com)05/31 Report--

This article shows you how to carry out ORACLE database connection and login verification, the content is concise and easy to understand, it will definitely brighten your eyes. I hope you can get something through the detailed introduction of this article.

The verification methods of Oracle database can be divided into two categories.

One is the login verification of non-privileged users.

One is the login verification of privileged users.

Privileged users refer to sysdba and sysoper, and users who log in with these two special permissions must add "as sysdba" or "as sysoper" clauses to the connection string.

For ordinary non-privileged users, the data dictionary check is used when logging in, and the user name and password are saved in the database.

That is, the database must be in the open state before such users can connect to the login database.

For privileged users, there are three ways of verification: operating system verification, password file verification, and other network authentication based on middleware.

What these three verification methods have in common is that the user name and password are independent of the database. In the event of database outage or database startup, privileged users can rely on these three verification methods to connect to the instance.

Here is my understanding of the verification method of privileged users

The user's behavior of connecting to the database is divided into remote connection and local connection.

Local connection refers to logging in to the ORACLE database server, setting $ORACLE_SID, and then connecting using some kind of verification.

Remote connection refers to connecting to the database through the ORACLE network component, which is characterized by indicating the network information of the database in the connection string.

For example, conn hr/hr@prod1.

In other words, even if you log in to the ORACLE database server, if you connect to the local database through a remote connection, this connection is considered a remote connection.

Privileged users' operating system-based authentication is limited to local connections in the UNIX/LINUX platform, and users of the user group specified in the Oracle database software must be logged in to use this connection verification.

The password file authentication method can be a remote connection or a local connection, the difference is that the operating system-based authentication method does not need to enter a user name password, while the password file verification method whether it is a remote connection or a local connection requires a user name and password.

Click (here) to collapse or open

-- locally connected operating system verification method

Conn / as sysdba

-- remote connection password file verification

Conn sys/oracle@PROD1 as sysdba

-- Local connection password file verification

Export ORACLE_SID=PROD1

Conn sys/oracle as sysdba

With regard to remote and local connections, the official document says that remote connections can also be verified using operating system authentication, but two requirements are met

1. The connection must be a secure connection as considered by the Oracle network file, and the connection in a common protocol like TCP/IP DECnet is not a secure connection.

2. The database server and client of remote connection must be both windows platform.

Specific connection string:

Click (here) to collapse or open

-- remote connection operating system verification

CONNECT / @ net_service_name AS SYSDBA

CONNECT / @ net_service_name AS SYSOPER

Thus, in most cases (on the UNIX/LINUX platform), the only way to use privileged users without logging in to the database server is to use password file verification.

The password file mainly records the user name, password, privileges and other information. According to the description of the entries option in the official document when creating a password file using orapwd tools, it can be inferred that the size of a user information (that is, an entry) should be 128bytes.

The creation of password files using orapwd tools, password file sharing, prohibition, modification, etc., official documents are written in detail, there are a lot of information on the Internet, there is not much detail here.

The above content is how to perform ORACLE database connection and login verification. Have you learned any knowledge or skills? If you want to learn more skills or enrich your knowledge reserve, you are welcome to follow the industry information channel.

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Database

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report