Nothing Special   »   [go: up one dir, main page]

CN107066409A - Port based on operation system redirects the method with communication data after-treatment - Google Patents

Port based on operation system redirects the method with communication data after-treatment Download PDF

Info

Publication number
CN107066409A
CN107066409A CN201710206751.2A CN201710206751A CN107066409A CN 107066409 A CN107066409 A CN 107066409A CN 201710206751 A CN201710206751 A CN 201710206751A CN 107066409 A CN107066409 A CN 107066409A
Authority
CN
China
Prior art keywords
port
data
api
new
write
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
CN201710206751.2A
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.)
Fujian Centerm Information Co Ltd
Original Assignee
Fujian Centerm Information 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 Fujian Centerm Information Co Ltd filed Critical Fujian Centerm Information Co Ltd
Priority to CN201710206751.2A priority Critical patent/CN107066409A/en
Publication of CN107066409A publication Critical patent/CN107066409A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F13/00Interconnection of, or transfer of information or other signals between, memories, input/output devices or central processing units
    • G06F13/38Information transfer, e.g. on bus
    • G06F13/382Information transfer, e.g. on bus using universal interface adapter
    • G06F13/385Information transfer, e.g. on bus using universal interface adapter for adaptation of a particular data processing system to different peripheral devices

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Computer And Data Communications (AREA)

Abstract

The present invention provides a kind of port redirection based on operation system and the method for communication data after-treatment, and methods described is:Interception service system is to the associative operation of port, and the associative operation is including opening COM1, data and communication close mouthful operation being read to COM1 write-in data, from COM1;When opening COM1, port is redirected, other COM1s are mapped to;When writing data to COM1, after-treatment is carried out to data, i.e., old instruction parsing, and be packaged with new instruction format, or data are encrypted and then issued;It is the same with write-in data when reading data to COM1, carry out after-treatment;When communication close mouthful is operated, the port occupancy to redirection discharges.The efficiency of operation system upgrading is improved, and realizes that new plant equipment instruction set is interacted with original producer inconsistent equipment that still can be normally carried out when introducing new producer's ancillary equipment.

Description

Port based on operation system redirects the method with communication data after-treatment
Technical field
The side with communication data after-treatment is redirected the present invention relates to financial technology field, more particularly to a kind of port Method.
Background technology
Current domestic major bank and other financial mechanisms generally carry out routine work using third party's ancillary equipment and handled, and use The common port such as serial ports, USB interface carries out data interaction.Because banking system renewal iteration speed is slower, part Mechanism district autonomous, third party producer switching is frequent, or situations such as product up-gradation, frequently results in following some problems and occur:
1) producer switches, and instruction set is different, it is impossible to seamless access existing business system;
2) peripheral integrated equipment due to product up-gradation or producer's switching, it is necessary to switch to several autonomous devices, original business The port of system only supports sole disposition, it is impossible to support many device configurations;
3) device upgrade, by communicating, slower serial communication is converted to the USB interface communication of speed, original business System only supports operation of serial-port, it is impossible to support USB interface to operate;
4) security consideration is in, needs to carry out ciphertext communication, original operation system in the communication process with ancillary equipment Only support to operate in plain text.
" a kind of serial port redirecting system " is disclosed in the prior art, and publication date is:2012.05.30, publication number For:CN202257551U Chinese patent, the utility model provides a kind of serial port redirecting system, including:Terminal, net Network router/hub and virtual desktop, terminal are set up data communication through network router/hub and virtual desktop and are connected; Terminal, which includes terminal, to be used to scanning, recognize and accessing in the way of file the serial port in terminal, complete control information and The transmission of data message, the serial ports controller for receiving and handling;Virtual desktop includes being used to create virtual serial port and corresponding Device node, set up terminal to virtual desktop serial port map;Intercept the I/O of application program and user to serial equipment Please sum operation, and be redirected to terminal processes, the virtual serial port controller that the result that terminal is returned is analyzed and handled. The invention has certain limitation on port type, and the invention the problem of solve with present patent application and differing, institute The technical scheme of use is also different.
The content of the invention
The technical problem to be solved in the present invention, is that providing a kind of port based on operation system redirects and communication number According to the method for after-treatment, solve when service application software is not upgraded, (such as serial ports is to USB interface liter after port upgrading Level) or integrated equipment to multiple autonomous devices switch after equipment access problem;By the after-treatment of data, solve When introducing new producer's ancillary equipment, the inconsistent caused service application software of new plant equipment instruction set and original producer can not be just The problem of often carrying out equipment interaction;Solve when the requirement of peripheral hardware communication security is upgraded, the encryption and decryption problem of data.
What the present invention was realized in:A kind of port based on operation system is redirected and communication data after-treatment Method, methods described is:Interception service system to the associative operation of port, the associative operation include opening COM1, Data and communication close mouthful operation are read to COM1 write-in data, from COM1;It is right when opening COM1 Port is redirected, and is mapped to other COM1s;When writing data to COM1, secondary place is carried out to data Reason, i.e., old instruction parsing, and be packaged with new instruction format, or data are encrypted and then issued;To logical It is the same with write-in data when believing that data are read in port, after-treatment is carried out, i.e., encapsulation is disassembled in instruction, or data are solved It is close;When communication close mouthful is operated, the port occupancy to redirection discharges.
Further, methods described is specially further:One plug-in unit is injected into operation system, is that follow-up function is real Support is now provided;
Global hook is registered in plug-in unit, so in operation system process initiation, being somebody's turn to do for registration global hook can be loaded Plug-in unit, realizes injection;
According to module name and function name search present communications mouthful open, read, write-in, shutoff operation API in business system Address in system process;
With original port API addresses in the new API addresses replacement system scheduler module of customized port in plug-in unit, And retain original port API address informations, so when system process calls port correlation API, what is called is communication The new API of mouth.
Further, the port is redirected specially:Operation system calls the new API of port to carry out opening logical Casually;
If communication mode is constant, simply port changes, then need to only change port ginseng in the new API of port is realized Number, and be called using original port API, return information is returned by the new API of port;Follow-up read-write shutoff operation Operated using original port API;
If communication mode changes, new traffic mode opening is carried out in the new API of port, and by operating result and return Information is returned by the new API of port;Follow-up read-write shutoff operation need to be handled equally, i.e., carried out using the new API of port Operation.
Further, the after-treatment is specially:Operation system calls the new API of port to carry out data write-in and reading Take;
If carrying out instruction escape, when data write, write-in data are first subjected to old instruction parsing, and entered with new command Row encapsulation, recalls original port API and is write, and by operating result and return information, returned by the new API of port Return;
In digital independent, first pass through and call original port API to read, the data of acquisition are solved with new command Analysis, and be packaged with old instruction, operating result and return information are returned by the new API of port;
If carrying out data ciphertext interaction, when data write, first write-in data are encrypted, recalled original logical Casually API is write, and by operating result and return information, is returned by the new API of port;In digital independent, first lead to Cross and call original port API to read, the data to acquisition are decrypted, by operating result and return information, pass through communication The new API of mouth is returned.
The invention has the advantages that:The present invention is based on redirecting by port, solves in service application software not During upgrading, the equipment after (such as serial ports is upgraded to U mouthfuls) or integrated equipment switch to multiple autonomous devices after port upgrading is visited Ask questions;By the after-treatment of data, solve introduce new producer's ancillary equipment when, new plant equipment instruction set with it is original Service application software can not be normally carried out the problem of equipment is interacted caused by producer is inconsistent;Solving will in peripheral hardware communication security When asking upgrading, the encryption and decryption problem of data.
Brief description of the drawings
The present invention is further illustrated in conjunction with the embodiments with reference to the accompanying drawings.
The schematic flow sheet that Fig. 1 injects for plug-in unit in the present invention.
Fig. 2 is the schematic flow sheet that port of the present invention is redirected.
Fig. 3 writes the schematic flow sheet of data for the present invention to COM1.
Fig. 4 is the schematic flow sheet that COM1 of the present invention reads data.
Embodiment
Refer to shown in Fig. 1 to Fig. 4, a kind of port based on operation system is redirected and communication data after-treatment Method, it is characterised in that:Methods described is:Interception service system is to the associative operation of port, and the associative operation is including beating COM1 is opened, data are write to COM1, data and communication close mouthful operation are read from COM1;It is logical opening When believing port, port is redirected, other COM1s are mapped to;When writing data to COM1, to data Carry out after-treatment, i.e., old instruction parsing and is packaged with new instruction format, or data are encrypted then under Hair;It is the same with write-in data when reading data to COM1, after-treatment is carried out, i.e. encapsulation, or logarithm are disassembled in instruction According to being decrypted;When communication close mouthful is operated, the port occupancy to redirection discharges.
Methods described is specially further:One plug-in unit is injected into operation system, is realized for follow-up function and branch is provided Hold;
Global hook is registered in plug-in unit, so in operation system process initiation, being somebody's turn to do for registration global hook can be loaded Plug-in unit, realizes injection;
According to module name and function name search present communications mouthful open, read, write-in, shutoff operation API in business system Address in system process;
Led to original in the new API of customized port in plug-in unit (referred to as new API) address replacement system scheduler module Casually API addresses (referred to as old API), and retain original port API address informations, so when system process calls port During related API, that call is the new API of port.
The port is redirected specially:Operation system calls the new API of port to carry out opening port;
If communication mode is constant, simply port changes (being such as mapped to serial ports 3 by serial ports 2), then real in the new API of port Port parameter only need to be changed in existing, and is called using original port API, return information passes through the new API of port Return;Follow-up read-write shutoff operation is operated using original port API;
If communication mode change (such as communicates from serial communication to HID and changed), new traffic is carried out in the new API of port Mode is opened, and operating result and return information are returned by the new API of port;Follow-up read-write shutoff operation need to be carried out equally Processing, i.e., operated using the new API of port.
The after-treatment is specially:Operation system calls the new API of port to carry out data write-in and reading;
If carrying out instruction escape, when data write, write-in data are first subjected to old instruction parsing, and entered with new command Row encapsulation, recalls original port API and is write, and by operating result and return information, returned by the new API of port Return;
In digital independent, first pass through and call original port API to read, the data of acquisition are solved with new command Analysis, and be packaged with old instruction, operating result and return information are returned by the new API of port;
If carrying out data ciphertext interaction, when data write, first write-in data are encrypted, recalled original logical Casually API is write, and by operating result and return information, is returned by the new API of port;In digital independent, first lead to Cross and call original port API to read, the data to acquisition are decrypted, by operating result and return information, pass through communication The new API of mouth is returned.
Although the foregoing describing the embodiment of the present invention, those familiar with the art should manage Solution, the specific embodiment described by us is merely exemplary, rather than for the restriction to the scope of the present invention, is familiar with this The equivalent modification and change that the technical staff in field is made in the spirit according to the present invention, should all cover the present invention's In scope of the claimed protection.

Claims (4)

1. a kind of port based on operation system redirects the method with communication data after-treatment, it is characterised in that:It is described Method is:Interception service system is to the associative operation of port, and the associative operation includes opening COM1, to COM1 Write data, data are read from COM1 and communication close mouthful operation;When opening COM1, port is carried out Redirect, be mapped to other COM1s;When writing data to COM1, after-treatment, i.e., old instruction are carried out to data Parsing, and be packaged with new instruction format, or data are encrypted and then issued;Number is being read to COM1 According to when, it is the same with write-in data, carry out after-treatment, i.e. encapsulation is disassembled in instruction, or data is decrypted;In communication close During mouth operation, the port occupancy to redirection discharges.
2. the port according to claim 1 based on operation system redirects the method with communication data after-treatment, It is characterized in that:Methods described is specially further:One plug-in unit is injected into operation system, realizes and provides for follow-up function Support;
Global hook is registered in plug-in unit, so in operation system process initiation, the plug-in unit of registration global hook can be loaded, Realize injection;
Opened, read according to module name and function name lookup present communications mouthful, write, the API of shutoff operation enters in operation system Address in journey;
With original port API addresses in the new API addresses replacement system scheduler module of customized port in plug-in unit, and protect Original port API address informations are stayed, so when system process calls port correlation API, what is called is that port is new API。
3. the port according to claim 2 based on operation system redirects the method with communication data after-treatment, It is characterized in that:The port is redirected specially:Operation system calls the new API of port to carry out opening port;
If communication mode is constant, simply port changes, then only need to change port parameter in the new API of port is realized, and It is called using original port API, return information is returned by the new API of port;Follow-up read-write shutoff operation makes Operated with original port API;
If communication mode changes, new traffic mode opening is carried out in the new API of port, and by operating result and return information Returned by the new API of port;Follow-up read-write shutoff operation need to be handled equally, i.e., operated using the new API of port.
4. the port according to claim 2 based on operation system redirects the method with communication data after-treatment, It is characterized in that:The after-treatment is specially:Operation system calls the new API of port to carry out data write-in and reading;
If carrying out instruction escape, when data write, write-in data are first subjected to old instruction parsing, and sealed with new command Dress, recalls original port API and is write, and by operating result and return information, is returned by the new API of port;
In digital independent, first pass through and call original port API to read, the data of acquisition are parsed with new command, and It is packaged with old instruction, operating result and return information is returned by the new API of port;
If carrying out data ciphertext interaction, when data write, first write-in data are encrypted, original port is recalled API is write, and by operating result and return information, is returned by the new API of port;In digital independent, tune is first passed through Read with original port API, the data to acquisition are decrypted, it is new by port by operating result and return information API is returned.
CN201710206751.2A 2017-03-31 2017-03-31 Port based on operation system redirects the method with communication data after-treatment Pending CN107066409A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201710206751.2A CN107066409A (en) 2017-03-31 2017-03-31 Port based on operation system redirects the method with communication data after-treatment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201710206751.2A CN107066409A (en) 2017-03-31 2017-03-31 Port based on operation system redirects the method with communication data after-treatment

Publications (1)

Publication Number Publication Date
CN107066409A true CN107066409A (en) 2017-08-18

Family

ID=59602572

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201710206751.2A Pending CN107066409A (en) 2017-03-31 2017-03-31 Port based on operation system redirects the method with communication data after-treatment

Country Status (1)

Country Link
CN (1) CN107066409A (en)

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101324918A (en) * 2008-07-25 2008-12-17 北京信城通数码科技有限公司 Method for host computer to perform dynamic switch for multi-vendor chip equipment data switching protocol
CN102404107A (en) * 2010-09-13 2012-04-04 腾讯科技(深圳)有限公司 Method, device, sending end and receiving end for guaranteeing input content safety
CN202257551U (en) * 2011-10-14 2012-05-30 深圳市京华科讯科技有限公司 Serial port redirection system
CN103678214A (en) * 2013-11-29 2014-03-26 青岛海信电器股份有限公司 Method for redirecting system console and display equipment
CN104331644A (en) * 2014-11-24 2015-02-04 北京邮电大学 Transparent encryption and decryption method for intelligent terminal file
CN105721566A (en) * 2016-01-29 2016-06-29 华为技术有限公司 Method for redirecting port, server and system

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101324918A (en) * 2008-07-25 2008-12-17 北京信城通数码科技有限公司 Method for host computer to perform dynamic switch for multi-vendor chip equipment data switching protocol
CN102404107A (en) * 2010-09-13 2012-04-04 腾讯科技(深圳)有限公司 Method, device, sending end and receiving end for guaranteeing input content safety
CN202257551U (en) * 2011-10-14 2012-05-30 深圳市京华科讯科技有限公司 Serial port redirection system
CN103678214A (en) * 2013-11-29 2014-03-26 青岛海信电器股份有限公司 Method for redirecting system console and display equipment
CN104331644A (en) * 2014-11-24 2015-02-04 北京邮电大学 Transparent encryption and decryption method for intelligent terminal file
CN105721566A (en) * 2016-01-29 2016-06-29 华为技术有限公司 Method for redirecting port, server and system

Similar Documents

Publication Publication Date Title
CN104408366B (en) Android application program authority usage behavior tracking based on Program instrumentation
CN105446713B (en) Method for secure storing and equipment
US20170329618A1 (en) Modification of write-protected memory using code patching
CN106790599A (en) It is a kind of based on multinuclear without lock buffer circle symbiosis virtual machine communication method
CN109151803B (en) Information interacting method and device, intelligent card chip and terminal
CN108509802A (en) A kind of application data divulgence prevention method and device
CN106201747B (en) Method for accessing intelligent password equipment under limited user of WINDOWS system
CN110569651A (en) file transparent encryption and decryption method and system based on domestic operating system
US20150113506A1 (en) Method and system for adaptive loading of application
CN109814896A (en) Server updating method, apparatus, computer system and readable storage system
US20150113502A1 (en) Method and system for encapsulation of application
CN110597496B (en) Method and device for acquiring bytecode file of application program
ITMI951510A1 (en) EMULATOR FOR A RELATIONAL DATABASE IN SQL LANGUAGE
CN106326733A (en) Method and apparatus for managing applications in mobile terminal
CN107391272A (en) The method and terminal of multi-process data interaction
CN105550582B (en) Access the method and system of virtual disk
CN115033348B (en) Method, system, equipment and medium for unified management of virtual machine and container
CN107066409A (en) Port based on operation system redirects the method with communication data after-treatment
CN106127092A (en) The smart card of a kind of COS system application stripping and method of work thereof
CN104331289A (en) Method and device for applying plug-in design application to flow processing
CN105677418B (en) The method and system of multiple and different voice protocols are realized in access device
CN104123371A (en) Transparent Windows kernel file filtering method based on hierarchical file system
CN106874063A (en) A kind of its recovery method as resource and device
CN101536561B (en) Policy execution in communication device
CN104751026B (en) Method for protecting software, software application method and the relevant apparatus of Android 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: 20170818

RJ01 Rejection of invention patent application after publication