CN107734046A - Method, service end, client and the system of remote operation database - Google Patents

Method, service end, client and the system of remote operation database Download PDF

Info

Publication number
CN107734046A
CN107734046A CN201711019929.9A CN201711019929A CN107734046A CN 107734046 A CN107734046 A CN 107734046A CN 201711019929 A CN201711019929 A CN 201711019929A CN 107734046 A CN107734046 A CN 107734046A
Authority
CN
China
Prior art keywords
database
service end
client
object identity
module
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN201711019929.9A
Other languages
Chinese (zh)
Inventor
邵辉
曹雪韬
王宏达
张连頔
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Shandong Inspur Genersoft Information Technology Co Ltd
Original Assignee
Shandong Inspur Genersoft Information Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Shandong Inspur Genersoft Information Technology Co Ltd filed Critical Shandong Inspur Genersoft Information Technology Co Ltd
Priority to CN201711019929.9A priority Critical patent/CN107734046A/en
Publication of CN107734046A publication Critical patent/CN107734046A/en
Pending legal-status Critical Current

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/02Protocols based on web technology, e.g. hypertext transfer protocol [HTTP]
    • H04L67/025Protocols based on web technology, e.g. hypertext transfer protocol [HTTP] for remote control or remote monitoring of applications
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/25Integrating or interfacing systems involving database management systems
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L63/00Network architectures or network communication protocols for network security
    • H04L63/08Network architectures or network communication protocols for network security for authentication of entities
    • H04L63/0876Network architectures or network communication protocols for network security for authentication of entities based on the identity of the terminal or configuration, e.g. MAC address, hardware or software configuration or device fingerprint
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/14Session management
    • H04L67/141Setup of application sessions

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Theoretical Computer Science (AREA)
  • Databases & Information Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • Computing Systems (AREA)
  • Computer Security & Cryptography (AREA)
  • Computer Hardware Design (AREA)
  • Data Mining & Analysis (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Power Engineering (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

The invention provides a kind of method, service end, client and the system of remote operation database, the method applied to service end includes:The data source for the database sets default port and object identity in advance;By the default port, the connection request that client is sent is received;According to the connection request, judge the client whether with the service end successful connection, if it is, the object identity is mapped into the client, and access the database;Receive the database operating instruction for the carrying object identity that the client is sent;According to the object identity, the database operating instruction is sent to the database, so that the database performs the database operating instruction;And operating result is returned into the client.Technical scheme provided by the invention can improve the security of database manipulation process.

Description

Method, service end, client and the system of remote operation database
Technical field
The present invention relates to computer communication technology field, more particularly to a kind of method of remote operation database, service end, Client and system.
Background technology
Under current internet historical background, the process of most of shared data needs to operate database, therefore How the database in server is operated, turn into focus of concern.
Generally, server where database is arranged to shared state, so that each visitor in the LAN where database Family end can operate to lane database in server.
However, server is arranged to shared state, it is meant that the data source of database will also be shared, be open so that clothes Any one client in LAN where business device can be modified to the arbitrary data in database, so as to reduce The security of database manipulation process.
The content of the invention
The embodiments of the invention provide a kind of method, service end, client and the system of remote operation database, improves number According to the security of storehouse operating process.
In a first aspect, the embodiments of the invention provide a kind of method of remote operation database, applied to service end, in advance For the data source of the database, default port and object identity are set, in addition to:
By the default port, the connection request that client is sent is received;
According to the connection request, judge the client whether with the service end successful connection, if it is, will described in Object identity maps to the client, and accesses the database;
Receive the database operating instruction for the carrying object identity that the client is sent;
According to the object identity, the database operating instruction is sent to the database, so that the database Perform the database operating instruction;And operating result is returned into the client.
Preferably, the data source for the database sets object identity, including:
Obtain the internet protocol address of the port numbers of the default port, the title of the data source and the service end IP address;
Institute is generated according to the IP address of the port numbers of the default port, the title of the data source and the service end State object identity.
Preferably, it is described according to the connection request, judge the client whether with the service end successful connection, bag Include:
The connection request, including:IP address and port numbers;
A1, judges whether the IP address is the IP address of the service end, if it is, performing A2, otherwise, performs A3;
A2, judges whether the port numbers are the default port numbers of the service end, if it is, performing A4, otherwise, performs A3;
A3, judge the client and the service end connection failure;
A4, judge the client and the service end successful connection.
Preferably, further comprise:
Prestore and access username and password used in database;
The access database, including:
The username and password prestored is sent to the database, after by the data origin authentication, accessed The database.
Second aspect, the embodiments of the invention provide a kind of method of far call database data, applied to client, The IP address of service end and default port numbers are obtained in advance, in addition to:
According to the IP address of the service end and the default port numbers, connection request is generated, and pass through the default end Mouthful, the connection request is sent to the service end;
After service end checking junction success, the data that incoming database is reflected from the service end are received The object identity in source;
Generation carries the database operating instruction of the object identity, and sends to the service end, so that the service The database operating instruction is sent to the database by end;
Receive the operating result that the service end returns.
Preferably, further comprise:
Prestore at least one database operation method;
Then, generation carries the database operating instruction of the object identity, including:
Receive the outside at least one method to be called determined from least one database operation method;
Using at least one method to be called and the object identity, the database operating instruction is generated.
The third aspect, the embodiments of the invention provide a kind of service end, including:Setup module, the first receiving module, judge Module, the second receiving module and operation module;
The setup module, for setting default port and object identity for the data source of the database;
First receiving module, for the default port set by the setup module, receive client hair The connection request sent;
The judge module, for the connection request received according to first receiving module, judge the visitor Family end whether with the service end successful connection, if it is, the object identity mapped into the client, and described in accessing Database;
Second receiving module, the database manipulation of the carrying object identity sent for receiving the client Instruction;
The operation module, for according to the object identity, the data that second receiving module is received Storehouse operational order is sent to the database, so that the database performs the database operating instruction;Operating result is returned Back to the client.
Preferably, the setup module, including:Acquiring unit and identification generation unit;
The acquiring unit, for obtaining the port numbers of the default port, the title of the data source and the clothes The internet protocol address IP address at business end;
The identification generation unit, port numbers, institute for the default port that is got according to the acquiring unit The IP address of the title and the service end of stating data source generates the object identity.
Preferably, the connection request, including:IP address and port numbers;
The judge module, for performing A1 to A4:
A1, judges whether the IP address is the IP address of the service end, if it is, performing A2, otherwise, performs A3;
A2, judges whether the port numbers are the default port numbers of the service end, if it is, performing A4, otherwise, performs A3;
A3, judge the client and the service end connection failure;
A4, judge the client and the service end successful connection.
Preferably, further comprise:Parameter memory module;
The parameter memory module, for username and password used in store access data storehouse;
The judge module, including:Connection unit;
The connection unit, for the username and password prestored to be sent into the database, by described After data origin authentication, the database is accessed.
Fourth aspect, the embodiments of the invention provide a kind of client, including:Acquisition module, the first sending module, mapping Receiving module, the second sending module and result receiving module;
The acquisition module, for the IP address for obtaining service end and default port numbers;
First sending module, for the IP address of the service end that is obtained according to the acquisition module and described pre- If port numbers, connection request is generated, and by the default port, the connection request is sent to the service end;
The mapping receiving module, for after service end checking junction success, receiving from the service end Reflect the object identity of the data source of incoming database;
Second sending module, the database operating instruction of the object identity is carried for generating, and sent to institute Service end is stated, so that the database operating instruction is sent to the database by the service end;
The result receiving module, the operating result returned for receiving the service end.
Preferably, further comprise:Method memory module;
Methods described memory module, for prestoring at least one database operation method;
Second sending module, including:Receiving unit and generation unit;
The receiving unit, for receive outside determine from least one database operation method it is at least one Method to be called;
The generation unit, at least one method to be called for being received using the receiving unit and described Object identity, generate the database operating instruction.
5th aspect, the embodiments of the invention provide a kind of system of remote operation database, including:Appoint in the third aspect Any described client in service end and fourth aspect described in one.
The embodiments of the invention provide a kind of method, service end, client and the system of remote operation database, is data The data source in storehouse sets default port, and sets object identity to cause data source as in server for the data source of database One service and register, and enable a client to carry out database corresponding to registered data source by default port Access;By presetting port, the connection request that client is sent is received, when judging client and service end company according to connection request When being connected into work(, illustrate that client has the authority for accessing database, therefore object identity is mapped into client, and access data Contacting between client and database is established in storehouse;The database operating instruction for the carrying object identity that client is sent is received, According to object identity, database operating instruction is sent to database, so that database performs database operating instruction, finally will Operating result returns to the client.According to object identity, database operating instruction is sent to database.As can be seen here, The embodiment of the present invention is by the way that the data source of database to be arranged to service and register so that client can only pass through default port and visit Database is asked, and the client that server is accessed by other ports can not access database, to reach to connection database The purpose that client is filtered, so as to improve the security of database manipulation process;Object identity is provided to client body end, Client is allowd database operating instruction to be sent to database, without service end is arranged to according to object identity Shared state, so as to improve the security of database manipulation process;The object identity carried according to database operating instruction, can Verify that the instruction received is database operating instruction, to avoid false command from carrying out faulty operation to database, so as to enter one Step improves the security of database manipulation process.
Brief description of the drawings
In order to illustrate more clearly about the embodiment of the present invention or technical scheme of the prior art, below will be to embodiment or existing There is the required accompanying drawing used in technology description to be briefly described, it should be apparent that, drawings in the following description are the present invention Some embodiments, for those of ordinary skill in the art, on the premise of not paying creative work, can also basis These accompanying drawings obtain other accompanying drawings.
Fig. 1 is a kind of method for far call database data applied to service end that one embodiment of the invention provides Flow chart;
Fig. 2 is the side for the far call database data that the another kind that one embodiment of the invention provides is applied to service end Method flow chart;
Fig. 3 is a kind of method for far call database data applied to client that one embodiment of the invention provides Flow chart;
Fig. 4 is the side for the far call database data that the another kind that one embodiment of the invention provides is applied to client Method flow chart;
Fig. 5 is a kind of service end structural representation that one embodiment of the invention provides;
Fig. 6 is another service end structural representation that one embodiment of the invention provides;
Fig. 7 is another service end structural representation that one embodiment of the invention provides;
Fig. 8 is a kind of client terminal structure schematic diagram that one embodiment of the invention provides;
Fig. 9 is another client terminal structure schematic diagram that one embodiment of the invention provides;
Figure 10 is a kind of structural representation of the system for remote operation database that one embodiment of the invention provides;
Figure 11 is a kind of remote operation for system applied to remote operation database that one embodiment of the invention provides The method flow diagram of database.
Embodiment
To make the purpose, technical scheme and advantage of the embodiment of the present invention clearer, below in conjunction with the embodiment of the present invention In accompanying drawing, the technical scheme in the embodiment of the present invention is clearly and completely described, it is clear that described embodiment is Part of the embodiment of the present invention, rather than whole embodiments, based on the embodiment in the present invention, those of ordinary skill in the art The every other embodiment obtained on the premise of creative work is not made, belongs to the scope of protection of the invention.
As shown in figure 1, the embodiments of the invention provide a kind of method of far call database data, applied to service End, comprises the following steps:
Step 101, default port and object identity are set for the data source of the database in advance.
Step 102, by the default port, the connection request that client is sent is received.
Step 103, according to the connection request, judge the client whether with the service end successful connection, if It is the object identity to be mapped into the client, and access the database;Otherwise, current process is terminated.
Step 104, the database operating instruction for the carrying object identity that the client is sent is received.
Step 105, according to the object identity, the database operating instruction is sent to the database, so that institute State database and perform the database operating instruction.
Step 106, operating result is returned into the client.
The embodiments of the invention provide a kind of method of remote operation database, applied to service end, for the number of database Default port is set according to source, and sets object identity to cause data source as one in server for the data source of database Service and register, and enable a client to conduct interviews to database corresponding to registered data source by default port; By presetting port, the connection request that client is sent is received, when judging that client connects into service end according to connection request During work(, illustrate that client has the authority for accessing database, therefore object identity is mapped into client, accesses database is built Vertical contacting between client and database;The database operating instruction for the carrying object identity that client is sent is received, according to Object identity, database operating instruction is sent to database, so that database performs database operating instruction, finally will operation As a result the client is returned to.According to object identity, database operating instruction is sent to database.As can be seen here, this hair Bright embodiment is by the way that the data source of database to be arranged to service and register so that client can only pass through default port and access number According to storehouse, and the client that server is accessed by other ports can not access database, to reach the client to connecting database The purpose filtered is held, so as to improve the security of database manipulation process;Object identity is provided to client body end so that Client can send database operating instruction, without service end is arranged into shared according to object identity to database State, so as to improve the security of database manipulation process;The object identity carried according to database operating instruction, is able to verify that The instruction received is database operating instruction, to avoid false command from carrying out faulty operation to database, so as to further carry The security of high database manipulation process.
In order to ensure the uniqueness of object identity, in one embodiment of the invention, described is the database Data source set object identity, including:
Obtain the internet protocol address of the port numbers of the default port, the title of the data source and the service end IP address;
Institute is generated according to the IP address of the port numbers of the default port, the title of the data source and the service end State object identity.
For the server having determined, the IP address of server is unique;The default port of server is server The port itself carried, each port corresponds to a port number, therefore the port numbers of default port are unique;In server Database only corresponds to a data source, therefore the title of data source is also unique, so be made up of above three data Object identity is also unique, so that the database that client can be in locked service end by object identity.
In order to ensure that each client can access service end by default port, in one embodiment of the present of invention In, it is described according to the connection request, judge the client whether with the service end successful connection, including:
The connection request, including:IP address and port numbers;
A1, judges whether the IP address is the IP address of the service end, if it is, performing A2, otherwise, performs A3;
A2, judges whether the port numbers are the default port numbers of the service end, if it is, performing A4, otherwise, performs A3;
A3, judge the client and the service end connection failure;
A4, judge the client and the service end successful connection.
In actual mechanical process, because the IP address of service end and default port numbers have uniqueness, therefore by testing Whether the IP address that card receives in request is the IP address of service end and whether port numbers are default port numbers to judge client End with service end whether successful connection.IP address in reception is asked is the IP address of service end, and it is default that port numbers, which are, During port numbers, illustrate that client has access rights, therefore judge client and service end successful connection
As shown in Fig. 2 the embodiments of the invention provide the method for another far call database data, applied to service End, comprises the following steps:
Step 201, by being that the connection for the default port reception client transmission that the data source of database is set please in advance Ask;
In embodiments of the present invention, default port must inherit remote interface, to enable default port by client Access, and port numbers are set with following order, LocateRegistry.createRegistry (n), wherein, n is port numbers, General port numbers are default port 1099.
Step 202, judge whether the IP address in connection request is the IP address of service end, if it is, performing step 203;Otherwise, step 209 is performed.
Step 203, judge the port numbers in connection request whether be service end default port numbers, if it is, performing step Rapid 204;Otherwise, step 209 is performed.
In embodiments of the present invention, only when the IP address that the IP address in connection request is service end, and connection request In port numbers when being the default port numbers of service end, client and service end successful connection, otherwise illustrate connection request for visitor Family end is sent to other servers or other ports.
Step 204, client and service end successful connection are judged.
Step 205, default object identity is mapped into client, and the username and password by prestoring accesses Database.
In embodiments of the present invention, the object identity of data source includes:The port numbers of default port, the title of data source with And the IP address of service end.For example, the port numbers of default port are 1099, the entitled ConAccess of data source, service end IP address is 192.*********, then the object identity of data source is 192.*********, 1099, ConAccess.In order to Client is facilitated to access database, the store path of the entitled data source of data source.Object identity is being mapped into client While, the username and password prestored is sent to database, the data source of database can be entered to username and password Row verifies that just establishing it after by checking, between client and database contacted by.
Step 206, the database operating instruction for the carrying object identity that client is sent is received.
In embodiments of the present invention, service end receives the database operating instruction of carrying object identity by presetting port. Database operating instruction includes:According to condition inquire about, operated by major key modification, by major key deletion etc..
Step 207, according to object identity, database operating instruction is sent to database.
In embodiments of the present invention, except setting object identity for data source in service end, or other services Object identity is set in the same way, therefore service end usually there will be multiple object identities, it is necessary to be sent according to client Object identity, determine client send instruction be database operating instruction.It is determined that the instruction that client is sent is data After the operational order of storehouse, database operating instruction is sent to database.
Step 208, operating result is returned into client.
Step 209, judge client and service end connection failure, and terminate current process.
In embodiments of the present invention, if it is determined that client and service end connection failure, then client can not just access Database.
As indicated at 3, the embodiments of the invention provide a kind of method of far call database data, applied to client, Comprise the following steps:
Step 301, the IP address of service end and default port numbers are obtained in advance.
Step 302, according to the IP address of the service end and the default port numbers, connection request is generated, and pass through institute Default port is stated, the connection request is sent to the service end.
Step 303, after service end checking junction success, receive from the service end and reflect incoming data The object identity of the data source in storehouse.
Step 304, generation carries the database operating instruction of the object identity, and sends to the service end, so that The database operating instruction is sent to the database by the service end.
Step 305, the operating result that the service end returns is received.
The embodiments of the invention provide a kind of method of far call database data, applied to client, obtains in advance The IP address of service end and default port numbers, the IP address of service end and the client ability of default port numbers are only got in advance Database in service end can be conducted interviews;Utilize the IP address of the service end obtained in advance and the generation connection of default port numbers Request, ensure that client can be successfully connected with service end;The data source that incoming database is reflected from service end is received afterwards Object identity;Generation carries the database operating instruction of object identity, and sends to service end, so that service end is according to object Mark, database is sent to by database operating instruction, finally receives the operating result that service end returns.As can be seen here, this hair Bright embodiment passes through the IP address for getting service end in advance and default port numbers so that client can be visited by default port Database is asked, is easy to service end to filter the client for connecting database, improves the security of database manipulation process;Root The object identity of the data source of incoming database is reflected according to service end, database operating instruction is sent to database, it is not necessary to The database in service end is conducted interviews under conditions of service end is shared state, so as to improve database manipulation process Security;Generation carries the database operating instruction of object identity so that service end is able to verify that the instruction received is data Storehouse operational order, to avoid false command from carrying out faulty operation to database, so as to further improve database manipulation process Security.
Corresponding operating is carried out to database for the ease of ground, in one embodiment of the invention, further comprised:In advance Store at least one database operation method;
Then, generation carries the database operating instruction of the object identity, including:
Receive the outside at least one method to be called determined from least one database operation method;
Using at least one method to be called and the object identity, the database operating instruction is generated.
At least one database operation method, when being operated every time to database, user are stored in the client in advance At least one method to be called can be selected according to application scenarios from least one database operation method, it is not necessary to treat Call method is write, so as to improve the efficiency that user is operated to database.
As indicated at 4, the embodiments of the invention provide the method for another far call database data, applied to client End, comprises the following steps:
Step 401, according to the IP address of the service end obtained in advance and default port numbers, connection request is generated, and pass through Default port, service end is sent to by connection request.
In embodiments of the present invention, the IP address for obtaining service end in advance and default port numbers are passed through so that client is given birth to Into connection request disclosure satisfy that the preparatory condition of successful connection, to ensure that client can be with service end successful connection.Send During connection request, service end position is determined according to the IP address of service end, determines to send connection request further according to default port numbers Port.
Step 402, after service end checking junction success, the data that incoming database is reflected from service end are received The object identity in source.
In embodiments of the present invention, due to service end can by each object identity map among service to client, it is necessary to The IP address of the port numbers of default port, the title of data source and service end in the object identity received is multiple Object identity corresponding to data source is determined in object identity.
Step 403, receive it is outside determined from least one database operation method prestored at least one treat Call method.
In embodiments of the present invention, at least a configuration file will be encapsulated by a database operation method, as long as adjusting every time Database is operated with configuration file can, it is not necessary to write database operation method again.It can also encapsulate multiple Configuration file, database is operated under different scenes with realizing.
Step 404, using at least one method to be called and object identity, database operating instruction is generated, and send extremely Service end.
In embodiments of the present invention, service end is identified by sending object and is able to verify that the instruction received is data Storehouse operational order, to avoid false command from carrying out faulty operation to database.If database operating instruction does not carry object mark Know, then service end not can determine that the execution object of the instruction, so as to produce mistake.
Step 405, the operating result that service end returns is received.
As shown in figure 5, the embodiments of the invention provide a kind of service end, including:Setup module 501, the first receiving module 502nd, judge module 503, the second receiving module 504 and operation module 505;
Setup module 501, for setting default port and object identity for the data source of the database;
First receiving module 502, for the default port set by setup module 501, receive client and send Connection request;
Judge module 503, for the connection request received according to the first receiving module 502, judge the client End whether with the service end successful connection, if it is, the object identity is mapped into the client, and access the number According to storehouse;
Second receiving module 504, the database manipulation of the carrying object identity sent for receiving the client Instruction;
Operation module 505, for according to the object identity, the database that the second receiving module 504 is received Operational order is sent to the database, so that the database performs the database operating instruction;Operating result is returned To the client.
As shown in fig. 6, the embodiments of the invention provide another service end,
Setup module 501, including:Acquiring unit 5011 and identification generation unit 5012;
Acquiring unit 5011, for obtaining the port numbers of the default port, the title of the data source and the clothes The internet protocol address IP address at business end;
Identification generation unit 5012, port numbers, institute for the default port that is got according to acquiring unit 5011 The IP address of the title and the service end of stating data source generates the object identity.
In one embodiment of the invention, the connection request, including:IP address and port numbers;
Judge module 503, for performing A1 to A4:
A1, judges whether the IP address is the IP address of the service end, if it is, performing A2, otherwise, performs A3;
A2, judges whether the port numbers are the default port numbers of the service end, if it is, performing A4, otherwise, performs A3;
A3, judge the client and the service end connection failure;
A4, judge the client and the service end successful connection.
As shown in fig. 7, the embodiments of the invention provide another service end,
Further comprise:Parameter memory module 701;
Parameter memory module 701, for username and password used in store access data storehouse;
Judge module 503, including:Connection unit 5031;
Connection unit 5031, for the username and password prestored to be sent into the database, by described After data origin authentication, the database is accessed.
As shown in figure 8, the embodiments of the invention provide a kind of client, including:Acquisition module 801, the first sending module 802nd, receiving module 803, the second sending module 804 and result receiving module 805 are mapped;
Acquisition module 801, for the IP address for obtaining service end and default port numbers;
First sending module 802, for the IP address of the service end that is obtained according to acquisition module 801 and described default Port numbers, connection request is generated, and by the default port, the connection request is sent to the service end;
Receiving module 803 is mapped, for after service end checking junction success, receiving and being reflected from the service end The object identity of the data source of incoming database;
Second sending module 804, the database operating instruction of the object identity is carried for generating, and sent to described Service end, so that the database operating instruction is sent to the database by the service end;
As a result receiving module 805, the operating result returned for receiving the service end.
As shown in figure 9, the embodiments of the invention provide another client,
Further comprise:Method memory module 901;
Method memory module 901, for prestoring at least one database operation method;
Second sending module 804, including:Receiving unit 8041 and generation unit 8042;
Receiving unit 8041, for receive outside determine from least one database operation method it is at least one Method to be called;
Generation unit 8042, at least one method to be called for being received using receiving unit 8041 and described Object identity, generate the database operating instruction.
The contents such as the information exchange between each unit, implementation procedure in said apparatus, due to implementing with the inventive method Example is based on same design, and particular content can be found in the narration in the inventive method embodiment, and here is omitted.
As shown in Figure 10, the embodiments of the invention provide a kind of system of remote operation database, including:Any of the above-described reality Apply the visitor 1002 in the service end 1001 and any of the above-described embodiment in example.
As shown in figure 11, the embodiments of the invention provide a kind of method of remote operation database, applied to remote operation The system of database, comprises the following steps:
Step 1101, according to the IP address of the service end obtained in advance and default port numbers, connection request is generated, and pass through Default port, service end is sent to by connection request.
In embodiments of the present invention, there is the client for accessing data base authority could obtain IP address and default end in advance Slogan.
Step 1102, by being that the connection for the default port reception client transmission that the data source of database is set please in advance Ask;
Step 1103, judge whether the IP address in connection request is the IP address of service end, if it is, performing step 1104;Otherwise, step 1114 is performed.
Step 1104, judge the port numbers in connection request whether be service end default port numbers, if it is, performing step Rapid 1105;Otherwise, step 1114 is performed.
Step 1105, client and service end successful connection are judged.
Step 1106, default object identity is mapped into client, and the username and password by prestoring is visited Ask database.
In embodiments of the present invention, multiple services can be directed in service end and object identity is set, will object identity be set Method encapsulation so that every time start service end when, all can automatically for it is at least one service set object identity, if set lose Lose, or mark repeats to set, then sends miscue.
Step 1107, the object identity for the data source that incoming database is reflected from service end is received.
In embodiments of the present invention, each object identity can be mapped to client by service end.
Step 1108, receive it is outside determined from least one database operation method prestored at least one treat Call method.
In embodiments of the present invention, for different operation scenarios, the method to be called that each operation scenario is used Deposit in configuration file, only need to select a configuration file every time, it is possible to realize and select method to be called.
Step 1109, using at least one method to be called and object identity, database operating instruction is generated, and send extremely Service end.
In embodiments of the present invention, because service end there may be the mapping of multiple object identities, therefore database is made Operational order carries object identity corresponding to database, so that the execution object for the instruction that service end determines to receive is data Storehouse.
Step 1110, the database operating instruction for the carrying object identity that client is sent is received.
Step 1111, according to object identity, database operating instruction is sent to database.
Step 1112, operating result is returned into client.
Step 1113, the operating result that service end returns is received.
In embodiments of the present invention, for that can understand the operating process of client, client is to the data in invoked procedure The key elements such as storehouse instruction, sending object, response object, returning result print out.
Step 1114, judge client and service end connection failure, and terminate current process.
In summary, each embodiment of the present invention at least has the advantages that:
1st, it is that the data source of database sets default port, and the data for database in one embodiment of the invention Source sets object identity to cause data source to service and register as one in server, and enables a client to by pre- If port conducts interviews to database corresponding to registered data source;By presetting port, receive the connection that client is sent and ask Ask, when judging client with service end successful connection according to connection request, illustrate that client has the authority for accessing database, Therefore object identity is mapped into client, accesses database establishes contacting between client and database;Receive client The database operating instruction for the carrying object identity that end is sent, according to object identity, database operating instruction is sent to data Storehouse, so that database performs database operating instruction, operating result is finally returned into the client.According to object identity, Database operating instruction is sent to database.As can be seen here, the embodiment of the present invention is by the way that the data source of database is arranged to Service and register so that client can only pass through default port and access database, and the visitor of server is accessed by other ports Family end can not access database, to reach the purpose filtered to the client for connecting database, so as to improve database behaviour Make the security of process;Object identity is provided to client body end so that client can be sent out according to object identity to database Database operating instruction is sent, without service end is arranged into shared state, so as to improve the safety of database manipulation process Property;The object identity carried according to database operating instruction, is able to verify that the instruction received is database operating instruction, to keep away Exempt from false command and faulty operation is carried out to database, so as to further improve the security of database manipulation process.
2nd, in one embodiment of the invention, the IP address of service end and default port numbers are obtained in advance, are only obtained in advance The client of IP address and default port numbers to service end could conduct interviews to the database in service end;Using obtaining in advance The IP address of the service end taken and default port numbers generation connection request, ensure that client can be successfully connected with service end;It The object identity for the data source that incoming database is reflected from service end is received afterwards;Generation carries the database manipulation of object identity Instruction, and send to service end, so that database operating instruction is sent to database, finally by service end according to object identity Receive the operating result that service end returns.As can be seen here, the embodiment of the present invention by get in advance service end IP address and Default port numbers so that client can access database by default port, be easy to client of the service end to connection database End is filtered, and improves the security of database manipulation process;Pair of the data source of incoming database is reflected according to service end As mark, database operating instruction is sent to database, it is not necessary to in service end under conditions of service end is shared state Database conduct interviews, so as to improve the security of database manipulation process;Generation carries the database manipulation of object identity Instruction so that service end is able to verify that the instruction received is database operating instruction, to avoid false command from entering database Row faulty operation, so as to further improve the security of database manipulation process.
3rd, in one embodiment of the invention, by storing at least one database operation method in client, it is directed to not Same scene, call method can be determined from least one database operation method, not write database manipulation side every time Method, improve the efficiency of database manipulation process.
4th, in one embodiment of the invention, in server stores user name and password so that when client accesses database, Without transmitting username and password by wide area network, the security of database manipulation process is further increased.
It should be noted that herein, such as first and second etc relational terms are used merely to an entity Or operation makes a distinction with another entity or operation, and not necessarily require or imply and exist between these entities or operation Any this actual relation or order.Moreover, term " comprising ", "comprising" or its any other variant be intended to it is non- It is exclusive to include, so that process, method, article or equipment including a series of elements not only include those key elements, But also the other element including being not expressly set out, or also include solid by this process, method, article or equipment Some key elements.In the absence of more restrictions, the key element limited by sentence "including a ...", it is not excluded that including Other identical factor in the process of the key element, method, article or equipment also be present.
One of ordinary skill in the art will appreciate that:Realizing all or part of step of above method embodiment can pass through Programmed instruction related hardware is completed, and foregoing program can be stored in computer-readable storage medium, the program Upon execution, the step of execution includes above method embodiment;And foregoing storage medium includes:ROM, RAM, magnetic disc or light Disk etc. is various can be with the medium of store program codes.
It is last it should be noted that:Presently preferred embodiments of the present invention is the foregoing is only, is merely to illustrate the skill of the present invention Art scheme, is not intended to limit the scope of the present invention.Any modification for being made within the spirit and principles of the invention, Equivalent substitution, improvement etc., are all contained in protection scope of the present invention.

Claims (10)

1. a kind of method of remote operation database, applied to service end, it is characterised in that be in advance the data of the database Source sets default port and object identity, in addition to:
By the default port, the connection request that client is sent is received;
According to the connection request, judge the client whether with the service end successful connection, if it is, by the object Identity map accesses the database to the client;
Receive the database operating instruction for the carrying object identity that the client is sent;
According to the object identity, the database operating instruction is sent to the database, so that the database performs The database operating instruction;And operating result is returned into the client.
2. according to the method for claim 1, it is characterised in that
The data source for the database sets object identity, including:
With obtaining the internet protocol address IP of the port numbers of the default port, the title of the data source and the service end Location;
It is described right to be generated according to the IP address of the port numbers of the default port, the title of the data source and the service end As mark;
And/or
It is described according to the connection request, judge the client whether with the service end successful connection, including:
The connection request, including:IP address and port numbers;
A1, judges whether the IP address is the IP address of the service end, if it is, performing A2, otherwise, performs A3;
A2, judges whether the port numbers are the default port numbers of the service end, if it is, performing A4, otherwise, performs A3;
A3, judge the client and the service end connection failure;
A4, judge the client and the service end successful connection.
3. according to the method for claim 1, it is characterised in that further comprise:
Prestore and access username and password used in database;
The access database, including:
The username and password prestored is sent to the database, after by the data origin authentication, described in access Database.
4. a kind of method of far call database data, applied to client, it is characterised in that obtain the IP of service end in advance Address and default port numbers, in addition to:
According to the IP address of the service end and the default port numbers, connection request is generated, and by the default port, will The connection request is sent to the service end;
After service end checking junction success, the data source that incoming database is reflected from the service end is received Object identity;
Generation carries the database operating instruction of the object identity, and sends to the service end, so that the service end will The database operating instruction is sent to the database;
Receive the operating result that the service end returns.
5. according to the method for claim 4, it is characterised in that further comprise:
Prestore at least one database operation method;
Then, generation carries the database operating instruction of the object identity, including:
Receive the outside at least one method to be called determined from least one database operation method;
Using at least one method to be called and the object identity, the database operating instruction is generated.
A kind of 6. service end, it is characterised in that including:Setup module, the first receiving module, judge module, the second receiving module And operation module;
The setup module, for setting default port and object identity for the data source of the database;
First receiving module, for the default port set by the setup module, receive what client was sent Connection request;
The judge module, for the connection request received according to first receiving module, judge the client Whether with the service end successful connection, if it is, the object identity is mapped into the client, and access the data Storehouse;
Second receiving module, the database manipulation of the carrying object identity sent for receiving the client refer to Order;
The operation module, for according to the object identity, the database that second receiving module is received to be grasped Make instruction to send to the database, so that the database performs the database operating instruction;Operating result is returned to The client.
7. service end according to claim 6, it is characterised in that
The setup module, including:Acquiring unit and identification generation unit;
The acquiring unit, for obtaining the port numbers of the default port, the title of the data source and the service end Internet protocol address IP address;
The identification generation unit, port numbers, the number for the default port that is got according to the acquiring unit The object identity is generated according to the title in source and the IP address of the service end;
And/or
The connection request, including:IP address and port numbers;
The judge module, for performing A1 to A4:
A1, judges whether the IP address is the IP address of the service end, if it is, performing A2, otherwise, performs A3;
A2, judges whether the port numbers are the default port numbers of the service end, if it is, performing A4, otherwise, performs A3;
A3, judge the client and the service end connection failure;
A4, judge the client and the service end successful connection;
And/or
Further comprise:Parameter memory module;
The parameter memory module, for username and password used in store access data storehouse;
The judge module, including:Connection unit;
The connection unit, for the username and password prestored to be sent into the database, passing through the data After the checking of source, the database is accessed.
A kind of 8. client, it is characterised in that including:Acquisition module, the first sending module, mapping receiving module, second send Module and result receiving module;
The acquisition module, for the IP address for obtaining service end and default port numbers;
First sending module, for the IP address of the service end obtained according to the acquisition module and the default end Slogan, connection request is generated, and by the default port, the connection request is sent to the service end;
The mapping receiving module, for after service end checking junction success, receiving and being mapped from the service end The object identity of the data source of the database to come over;
Second sending module, the database operating instruction of the object identity is carried for generating, and sent to the clothes Business end, so that the database operating instruction is sent to the database by the service end;
The result receiving module, the operating result returned for receiving the service end.
9. the client according to claim, it is characterised in that
Further comprise:Method memory module;
Methods described memory module, for prestoring at least one database operation method;
Second sending module, including:Receiving unit and generation unit;
The receiving unit, for receive it is outside determined from least one database operation method at least one wait to adjust Use method;
The generation unit, at least one method to be called received using the receiving unit and the object Mark, generates the database operating instruction.
A kind of 10. system of remote operation database, it is characterised in that including:Any described service in claim 6 to 7 Any described client in end and claim 8 to 9.
CN201711019929.9A 2017-10-26 2017-10-26 Method, service end, client and the system of remote operation database Pending CN107734046A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201711019929.9A CN107734046A (en) 2017-10-26 2017-10-26 Method, service end, client and the system of remote operation database

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201711019929.9A CN107734046A (en) 2017-10-26 2017-10-26 Method, service end, client and the system of remote operation database

Publications (1)

Publication Number Publication Date
CN107734046A true CN107734046A (en) 2018-02-23

Family

ID=61201776

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201711019929.9A Pending CN107734046A (en) 2017-10-26 2017-10-26 Method, service end, client and the system of remote operation database

Country Status (1)

Country Link
CN (1) CN107734046A (en)

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110300185A (en) * 2019-07-12 2019-10-01 苏州浪潮智能科技有限公司 A kind of NTB communication means, device, equipment and storage medium
CN111026794A (en) * 2019-11-26 2020-04-17 山东中创软件商用中间件股份有限公司 Data management method, device, equipment and medium based on data source
CN111274085A (en) * 2020-01-14 2020-06-12 中科驭数(北京)科技有限公司 Database monitoring system and method
CN115203676A (en) * 2022-09-06 2022-10-18 北京圣博润高新技术股份有限公司 Database connection method, database connection device, proxy server and medium

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101005505A (en) * 2006-01-20 2007-07-25 国际商业机器公司 Systems and methods for communication with database client users
CN101923678A (en) * 2010-07-30 2010-12-22 武汉天喻信息产业股份有限公司 Data security protection method of enterprise management software
CN102984138A (en) * 2012-11-16 2013-03-20 华为技术有限公司 Method, device and system for obtaining object
CN103679368A (en) * 2013-12-13 2014-03-26 清华大学 Wafer CMP processing information management system
CN104243532A (en) * 2013-06-21 2014-12-24 鸿富锦精密工业(深圳)有限公司 Data access method and system
US20160380876A1 (en) * 2015-06-23 2016-12-29 Lenovo Enterprise Solutions (Singapore) Pte. Ltd. Populating forwarding database tables in a fabric environment

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101005505A (en) * 2006-01-20 2007-07-25 国际商业机器公司 Systems and methods for communication with database client users
CN101923678A (en) * 2010-07-30 2010-12-22 武汉天喻信息产业股份有限公司 Data security protection method of enterprise management software
CN102984138A (en) * 2012-11-16 2013-03-20 华为技术有限公司 Method, device and system for obtaining object
CN104243532A (en) * 2013-06-21 2014-12-24 鸿富锦精密工业(深圳)有限公司 Data access method and system
CN103679368A (en) * 2013-12-13 2014-03-26 清华大学 Wafer CMP processing information management system
US20160380876A1 (en) * 2015-06-23 2016-12-29 Lenovo Enterprise Solutions (Singapore) Pte. Ltd. Populating forwarding database tables in a fabric environment

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110300185A (en) * 2019-07-12 2019-10-01 苏州浪潮智能科技有限公司 A kind of NTB communication means, device, equipment and storage medium
CN110300185B (en) * 2019-07-12 2022-06-07 苏州浪潮智能科技有限公司 NTB communication method, device, equipment and storage medium
CN111026794A (en) * 2019-11-26 2020-04-17 山东中创软件商用中间件股份有限公司 Data management method, device, equipment and medium based on data source
CN111274085A (en) * 2020-01-14 2020-06-12 中科驭数(北京)科技有限公司 Database monitoring system and method
CN115203676A (en) * 2022-09-06 2022-10-18 北京圣博润高新技术股份有限公司 Database connection method, database connection device, proxy server and medium
CN115203676B (en) * 2022-09-06 2023-01-03 北京圣博润高新技术股份有限公司 Database connection method, database connection device, proxy server and medium

Similar Documents

Publication Publication Date Title
CN107507305B (en) A kind of access control system of residential community and door opening method based on wechat
CN107493280A (en) Method, intelligent gateway and the certificate server of user authentication
CN103249045B (en) A kind of methods, devices and systems of identification
CN107734046A (en) Method, service end, client and the system of remote operation database
CN109510849A (en) The account number method for authenticating and device of cloud storage
CN110365701B (en) Client terminal equipment management method and device, computing equipment and storage medium
CN102045375B (en) Remote command interaction method and bastion host
CN108769186B (en) Service authority control method and device
CN106060072B (en) Authentication method and device
CN101764808B (en) Authentication processing method and system for automatic login as well as server
CN106131066B (en) A kind of authentication method and device
CN101986598B (en) Authentication method, server and system
CN106685949A (en) Container access method, container access device and container access system
CN106844489A (en) A kind of file operation method, device and system
CN107872445A (en) Access authentication method, equipment and Verification System
CN104580553A (en) Identification method and device for network address translation device
CN106790209A (en) A kind of login authentication method and system
CN108632325A (en) A kind of call method and device of application
CN106331003A (en) Method and device for accessing application portal system on cloud desktop
CN108259457A (en) A kind of WEB authentication methods and device
CN106603721A (en) Remote control method and system and remote control client
CN106453349A (en) An account number login method and apparatus
CN103905382A (en) Broadband user dial-up authentication error processing method and system
CN105163317A (en) Network access method, server, terminal and system
CN107135506A (en) A kind of portal authentication methods, apparatus and system

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
RJ01 Rejection of invention patent application after publication

Application publication date: 20180223

RJ01 Rejection of invention patent application after publication