CN105872102A - File uploading and downloading method - Google Patents
File uploading and downloading method Download PDFInfo
- Publication number
- CN105872102A CN105872102A CN201610395563.4A CN201610395563A CN105872102A CN 105872102 A CN105872102 A CN 105872102A CN 201610395563 A CN201610395563 A CN 201610395563A CN 105872102 A CN105872102 A CN 105872102A
- Authority
- CN
- China
- Prior art keywords
- file
- web server
- user
- browser
- local
- 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.)
- Granted
Links
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L67/00—Network arrangements or protocols for supporting network services or applications
- H04L67/01—Protocols
- H04L67/06—Protocols specially adapted for file transfer, e.g. file transfer protocol [FTP]
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F16/00—Information retrieval; Database structures therefor; File system structures therefor
- G06F16/90—Details of database functions independent of the retrieved data types
- G06F16/95—Retrieval from the web
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L67/00—Network arrangements or protocols for supporting network services or applications
- H04L67/01—Protocols
- H04L67/02—Protocols based on web technology, e.g. hypertext transfer protocol [HTTP]
Landscapes
- Engineering & Computer Science (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Databases & Information Systems (AREA)
- Theoretical Computer Science (AREA)
- Data Mining & Analysis (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Information Transfer Between Computers (AREA)
Abstract
The invention relates to a file uploading and downloading method. When a user uploads a file to a Web server through a browser page or downloads the file from the Web server; a browser transmits file uploading and downloading commands to a local file agent program of a user computer through HTTP (hyper text transport protocol); the file uploading and downloading operation processing, including the pop-up of a man-computer interface for the user to select the local file to be uploaded or to select the storage position of the downloaded file in the local area and to call a local API (application program interface) to process the file before the file uploading and during the file downloading, is completed by a file agent program; the browser transmits the file uploading and downloading commands to the file agent program, and meanwhile transmits conversation mark data of the conversation between the browser and the Web server to the file agent program; the conversion mark data is included into the a file uploading and downloading HTTP request submitted to the Web server by the file agent program in a mode of conversion mark data submission by the browser agreed by the Web server.
Description
Technical field
The invention belongs to Web information technical field, particularly one use browser to upload user, download
Do not call the local API file to uploading, downloading by browser plug-in or control during file to carry out
The method processed.
Background technology
People are using Web system when, it is often necessary to by transmitting file, download file on browser.
If when upper transmitting file, download file, need to call local API (such as local crypto module) to uploading
Or the file downloaded carries out processing and (is such as encrypted the file uploaded and/or digital signature, to download
File is decrypted and/or signature verification), then this point cannot directly be accomplished by browser.Common practice
Be by the browser plug-in (Plug-in) developed specially or control (such as ActiveX) carry out files passe,
File download, and in files passe, downloading process by plug-in unit or control call local API to uploading, under
The file process carried processes.The greatest problem of this scheme is browser plug-in or control depends on browser
Type, plug-in unit or control for a kind of Development of Web Browser can not use in another browser, need pin
To the different corresponding plug-in units of Development of Web Browser or control, the interoperability of the most this scheme is poor.
For this problem, applicant is at its patent application " a kind of data for browser and file
Encryption method " (number of patent application: 201410427298.4) proposes corresponding solution, the program
There is a problem that: the file upload, downloaded all has to pass through browser, quite carried out twice literary composition
Transmission is uploaded or downloaded to part, and during upper transmitting file, file is transferred to local agent program from browser, then from
Local agent program uploads to Web server again, or when downloading file, file is downloaded from Web server
To local agent program, then it is transferred to browser again from local agent program;The most not only efficiency is low, and
And additionally occupy system resource (such as memory source).
Summary of the invention
The purpose of the present invention is to propose to one use browser to upload user, download in file processes and do not pass through
Browser plug-in or control just can call the method that the file uploaded, download is processed by local API, with
Overcome the deficiencies in the prior art.
To achieve these goals, the technical solution adopted in the present invention is: a kind of File Upload and Download method,
Described method includes again file uploading method and document down loading method.
File uploading method is specific as follows:
When user uploads one by the files passe button on the click browser page or instruction to Web server
During individual file, browser is by files passe order, target URL (the Uniform Resource of files passe
Locator, or Universal Resource Locator) and browser and Web server between session
Session identification data be submitted to, by HTTP request, the File Agent program that subscriber computer is local;File generation
After reason program receives files passe order, eject a personal-machine interactive interface and allow user select basis to be uploaded
Ground file;After user selects file to be uploaded by human-computer interaction interface, File Agent program reads this locality
File, calls local API and processes file (as being encrypted file and/or digital signature), so
Files passe after processing according to target URL of files passe afterwards is to Web server;Uploading files to
During Web server, File Agent program is pressed the browser of Web server agreement and is submitted session identification number to
According to mode just between browser and Web server the session identification data of session be included in files passe
In HTTP request;
Document down loading method is as follows:
When the file download button on user's click browser page or link download a literary composition from Web server
During part, browser is by file download order, instruction file URL (Uniform of position in Web server
Resource Locator, or Universal Resource Locator) and browser and Web service
The session identification data of session between device are submitted to, by HTTP request, the File Agent journey that subscriber computer is local
Sequence;After File Agent program receives file download order, eject a personal-machine interactive interface and allow user select
Download file at local deposit position;Select to download file in this locality by human-computer interaction interface user
After deposit position, File Agent program is presented a paper download HTTP request to Web server, has finger in request
Show the URL of file position in Web server and submit session mark to by the browser of Web server agreement
The session identification data of session between browser and Web server that the mode of knowledge data is submitted to;File Agent
Program receives after the file that Web server is downloaded, and calls local API to downloading the file (data) passed
Carrying out processing (as being decrypted file and/or digital signature authentication), the file after then processing preserves
At the local deposit position that user is selected by human-computer interaction interface;
Described Web server is a Web information system or the service end system of application system;
Described File Agent program be one operate in that subscriber computer is local, uploaded by browser user,
Download file processes calls local API the file uploaded, download is processed and is finally completed on file
Biography, the program of download process;
Described session identification data are to include the Session ID of session between Web system and user browser
(Session ID) and the data of other session related information;Other session related information described is for limiting
Determine the information of session.
If during files passe, download process, the session of local file Agent submitted to by browser
Mark data are the data after the encryption keys that Web server uses user, the most described File Agent
After program session identification data after receiving the encryption that browser is submitted to, use the decruption key solution of user
Close acquisition session identification data.
From above summary of the invention it can be seen that, method based on the present invention, when user is by transmitting file on browser
Time, Web browser is the most directly by files passe to Web server, but is entered by local File Agent program
Row upload operation is also called local API before upload operation and is processed file;And when user is by browsing
When file downloaded by device, Web browser the most directly downloads file from Web server, but by local file generation
Reason program is downloaded operation and calls local API after file download and process file;Based on this
Bright method, when user uploaded by browser, download file and needs call local API to uploading, under
When the file carried processes, browser is without using plug-in unit or control to call local API, and this is just greatly increased
Files passe, download the suitability of Web page, do not limited by particular browser type.With patent Shen
Please " a kind of data for browser and file encrypting method " (number of patent application: 201410427298.4)
In scheme different, the file in the present invention, upload, downloaded, all without browser, the most not only carries
High files passe, the efficiency (speed is faster) of download, and decrease and system resource is taken.
Accompanying drawing explanation
Fig. 1 is the method schematic diagram of the present invention.
Detailed description of the invention
The invention will be further described below in conjunction with the accompanying drawings.
Http communication between browser and File Agent program can pass through automatic HTTP POST, point to this locality
Page link (HTTP GET), shell script realize, including use HTML framework (FRAME), AJAX
Deng;Shell script and local file Agent is used to need to solve cross-domain script (Cross by HTTP
Domain Script) problem.All these, it is described, in many open source informations in the Internet also
The information of many this respects.
File position in Web server is uploaded or downloaded to browser to the statement that local file Agent transmits
The local API that between URL, browser and the Web server put, the session identification data of session, needs call
Instruction (such as which API module and interface function title) and call the information such as parameter of local API and can compile
Code in submitting to the URL of HTTP request of local file Agent, as coding in path, Query
In String, or it is placed in the FORM data of Agent of presenting a paper, or is placed on self-defining
In HTTP header (when being generated HTTP request by script).
Browser is submitted to by HTTP request between browser and the Web server of local file Agent
The session identification data of session, are obtained by shell script by browser, or are returned to by Web server
In page code (in JavaScrypt code).
If during files passe, download process, the session of local file Agent submitted to by browser
Mark data are the data after the encryption keys that Web server uses user, then encryption key is permissible
It is the PKI of user or a symmetric key.
If the user encryption key that session identification data encryption is used by Web server is PKI, then user
Decruption key is corresponding private key, and Web server is counted from user by HTTP request, response by browser
File Agent program acquisition encryption key (i.e. PKI) that calculation machine is local, and File Agent program is from local certificate
Storehouse or crypto module obtain customer digital certificate or PKI, and in acquisition process, file Agent is by man-machine friendship
Interface for users selects in available digital certificate or PKI mutually, such as, shows the digital certificate of private key
Or PKI selects for user;Or the user account data of Web server is preserved the PKI of user, Web
Server obtains encryption key (i.e. PKI) by the account information of user
If the user encryption key that session identification data encryption is used by Web server is symmetric key, then use
The decruption key at family is same key, and Web server obtains encryption key from the account data of user, such as
Symmetric key is derived from password.
Other unaccounted concrete technology implementations, for those skilled in the relevant art be it is known that
Self-explantory.
Claims (8)
1. a file uploading method, it is characterised in that this document method for uploading comprises the following steps:
When user by the files passe button on the click browser page or instruction upload a file to Web server time, browser by files passe order, between target URL of files passe and browser and Web server the session identification data of session by HTTP request be submitted to subscriber computer this locality File Agent program;
After File Agent program receives files passe order, eject a personal-machine interactive interface to allow user select local file to be uploaded;
After user selects file to be uploaded by human-computer interaction interface, File Agent program reads local file, calls local API and processes file, and the files passe after then processing according to target URL of files passe is to Web server;During uploading files to Web server, File Agent program submits to the mode of session identification data the session identification data of session between browser and Web server to be included in files passe HTTP request by the browser that Web server is arranged.
File uploading method the most according to claim 1, it is characterized in that, if in files passe processing procedure, the session identification data of local file Agent submitted to by browser is the data after the encryption keys that Web server uses user, after the most described File Agent program session identification data after receiving the encryption that browser is submitted to, the decryption key decryption of user is used to obtain session identification data.
File uploading method the most according to claim 2, it is characterized in that, if the user encryption key that session identification data encryption is used by Web server is PKI, then the decruption key of user is corresponding private key, Web server obtains encryption key by HTTP request, response from the File Agent program that subscriber computer is local by browser, or Web server obtains encryption key i.e. PKI by the account information of user.
File uploading method the most according to claim 2, it is characterized in that, if the user encryption key that session identification data encryption is used by Web server is symmetric key, then the decruption key of user is same key, and Web server obtains encryption key from the account data of user.
5. a document down loading method, it is characterised in that this document method for down loading comprises the following steps:
When the file download button on user's click browser page or link download a file from Web server, the session identification data of file download order, the instruction URL of file position in Web server and session between browser and Web server are submitted to, by HTTP request, the File Agent program that subscriber computer is local by browser;
After File Agent program receives file download order, eject a personal-machine interactive interface to allow user select the deposit position downloading file in this locality;
Select to download file after local deposit position by human-computer interaction interface user, File Agent program is presented a paper download HTTP request to Web server, and this document downloads the session identification data of session between the URL comprising instruction file position in Web server in HTTP request and browser and the Web server submitting to the mode of session identification data to submit to by the browser of Web server agreement;
File Agent program receives after the file that Web server is downloaded, and calls local API and processes downloading the file passed, and the file after then processing is saved in the local deposit position that user is selected by human-computer interaction interface.
Document down loading method the most according to claim 5, is characterized in that:
If in file download processing procedure, the session identification data of local file Agent submitted to by browser is the data after the encryption keys that Web server uses user, after the most described File Agent program session identification data after receiving the encryption that browser is submitted to, the decryption key decryption of user is used to obtain session identification data.
File Upload and Download method the most according to claim 6, it is characterized in that: if the user encryption key that session identification data encryption is used by Web server is PKI, then the decruption key of user is corresponding private key, Web server obtains encryption key by HTTP request, response from the File Agent program that subscriber computer is local by browser, or Web server obtains encryption key i.e. PKI by the account information of user.
File Upload and Download method the most according to claim 6, it is characterized in that: if the user encryption key that session identification data encryption is used by Web server is symmetric key, then the decruption key of user is same key, and Web server obtains encryption key from the account data of user.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201610395563.4A CN105872102B (en) | 2016-06-06 | 2016-06-06 | A kind of File Upload and Download method |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201610395563.4A CN105872102B (en) | 2016-06-06 | 2016-06-06 | A kind of File Upload and Download method |
Publications (2)
Publication Number | Publication Date |
---|---|
CN105872102A true CN105872102A (en) | 2016-08-17 |
CN105872102B CN105872102B (en) | 2018-12-18 |
Family
ID=56676042
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201610395563.4A Active CN105872102B (en) | 2016-06-06 | 2016-06-06 | A kind of File Upload and Download method |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN105872102B (en) |
Cited By (15)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN106375441A (en) * | 2016-08-31 | 2017-02-01 | 北京深思数盾科技股份有限公司 | Function extension method based on WEB browser and terminal device |
CN106506676A (en) * | 2016-11-24 | 2017-03-15 | 武汉理工大学 | Document transmission processing method and aid system |
CN106657219A (en) * | 2016-09-20 | 2017-05-10 | 深圳创维-Rgb电子有限公司 | Intelligent device-based file uploading and downloading method |
CN106850819A (en) * | 2017-02-17 | 2017-06-13 | 深圳市中博睿存信息技术有限公司 | A kind of method and system for improving object storage security |
CN107172180A (en) * | 2017-06-05 | 2017-09-15 | 深圳市成为信息技术有限公司 | A kind of peripheral hardware plateform system and its operation method and application method |
CN107368601A (en) * | 2017-07-26 | 2017-11-21 | 成都三零盛安信息系统有限公司 | local data access method and device |
CN107483505A (en) * | 2017-09-29 | 2017-12-15 | 武汉斗鱼网络科技有限公司 | The method and system that a kind of privacy of user in Video chat is protected |
CN107517252A (en) * | 2017-08-22 | 2017-12-26 | 福建中金在线信息科技有限公司 | A kind of file download control method, apparatus and system |
CN107944253A (en) * | 2017-12-12 | 2018-04-20 | 深圳创维数字技术有限公司 | A kind of third party APK endorsement methods, electronic equipment and storage medium |
CN108234539A (en) * | 2016-12-14 | 2018-06-29 | 北京金山云网络技术有限公司 | A kind of file upload, download, transmission method and device |
CN108289100A (en) * | 2018-01-25 | 2018-07-17 | 北京深思数盾科技股份有限公司 | A kind of safety access method, terminal device and system |
CN110581886A (en) * | 2019-08-29 | 2019-12-17 | 大唐网络有限公司 | File saving system and method |
CN111309473A (en) * | 2020-01-17 | 2020-06-19 | 政采云有限公司 | Data downloading method, device, equipment and medium |
CN113094607A (en) * | 2021-04-08 | 2021-07-09 | 百度在线网络技术(北京)有限公司 | Method and device for acquiring local resources |
CN114095491A (en) * | 2021-10-31 | 2022-02-25 | 郑州云海信息技术有限公司 | Method, device and equipment for uploading web page application file and readable medium |
Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN102917074A (en) * | 2012-11-09 | 2013-02-06 | 北京奇虎科技有限公司 | Server-side browser realization method and server |
CN103812882A (en) * | 2012-11-06 | 2014-05-21 | 腾讯科技(深圳)有限公司 | Method and system for transferring files |
CN104217173A (en) * | 2014-08-27 | 2014-12-17 | 武汉理工大学 | Method of encrypting data and files for browser |
-
2016
- 2016-06-06 CN CN201610395563.4A patent/CN105872102B/en active Active
Patent Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103812882A (en) * | 2012-11-06 | 2014-05-21 | 腾讯科技(深圳)有限公司 | Method and system for transferring files |
CN102917074A (en) * | 2012-11-09 | 2013-02-06 | 北京奇虎科技有限公司 | Server-side browser realization method and server |
CN104217173A (en) * | 2014-08-27 | 2014-12-17 | 武汉理工大学 | Method of encrypting data and files for browser |
Non-Patent Citations (1)
Title |
---|
周庆: "一种基于ASP实现无组件上传文件的新方法", 《微机发展》 * |
Cited By (21)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN106375441A (en) * | 2016-08-31 | 2017-02-01 | 北京深思数盾科技股份有限公司 | Function extension method based on WEB browser and terminal device |
CN106657219A (en) * | 2016-09-20 | 2017-05-10 | 深圳创维-Rgb电子有限公司 | Intelligent device-based file uploading and downloading method |
US10785285B2 (en) | 2016-09-20 | 2020-09-22 | Shenzhen Skyworth-Rgb Electronic Co., Ltd. | File uploading and downloading method based on a smart device |
CN106657219B (en) * | 2016-09-20 | 2019-10-01 | 深圳创维-Rgb电子有限公司 | File based on smart machine uploads and method for down loading |
CN106506676A (en) * | 2016-11-24 | 2017-03-15 | 武汉理工大学 | Document transmission processing method and aid system |
CN106506676B (en) * | 2016-11-24 | 2019-05-24 | 武汉理工大学 | Document transmission processing method and auxiliary system |
CN108234539A (en) * | 2016-12-14 | 2018-06-29 | 北京金山云网络技术有限公司 | A kind of file upload, download, transmission method and device |
CN106850819A (en) * | 2017-02-17 | 2017-06-13 | 深圳市中博睿存信息技术有限公司 | A kind of method and system for improving object storage security |
CN107172180A (en) * | 2017-06-05 | 2017-09-15 | 深圳市成为信息技术有限公司 | A kind of peripheral hardware plateform system and its operation method and application method |
CN107368601A (en) * | 2017-07-26 | 2017-11-21 | 成都三零盛安信息系统有限公司 | local data access method and device |
CN107517252A (en) * | 2017-08-22 | 2017-12-26 | 福建中金在线信息科技有限公司 | A kind of file download control method, apparatus and system |
CN107483505A (en) * | 2017-09-29 | 2017-12-15 | 武汉斗鱼网络科技有限公司 | The method and system that a kind of privacy of user in Video chat is protected |
CN107483505B (en) * | 2017-09-29 | 2020-10-16 | 武汉斗鱼网络科技有限公司 | Method and system for protecting user privacy in video chat |
CN107944253A (en) * | 2017-12-12 | 2018-04-20 | 深圳创维数字技术有限公司 | A kind of third party APK endorsement methods, electronic equipment and storage medium |
CN108289100A (en) * | 2018-01-25 | 2018-07-17 | 北京深思数盾科技股份有限公司 | A kind of safety access method, terminal device and system |
CN110581886A (en) * | 2019-08-29 | 2019-12-17 | 大唐网络有限公司 | File saving system and method |
CN111309473A (en) * | 2020-01-17 | 2020-06-19 | 政采云有限公司 | Data downloading method, device, equipment and medium |
CN113094607A (en) * | 2021-04-08 | 2021-07-09 | 百度在线网络技术(北京)有限公司 | Method and device for acquiring local resources |
CN113094607B (en) * | 2021-04-08 | 2024-04-19 | 百度在线网络技术(北京)有限公司 | Method and device for obtaining local resources |
CN114095491A (en) * | 2021-10-31 | 2022-02-25 | 郑州云海信息技术有限公司 | Method, device and equipment for uploading web page application file and readable medium |
CN114095491B (en) * | 2021-10-31 | 2023-08-22 | 郑州云海信息技术有限公司 | Method, device and equipment for uploading web page application file and readable medium |
Also Published As
Publication number | Publication date |
---|---|
CN105872102B (en) | 2018-12-18 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN105872102A (en) | File uploading and downloading method | |
US10818291B2 (en) | Method and apparatus for interacting information | |
CN104468531B (en) | The authorization method of sensitive data, device and system | |
CN105025041B (en) | The methods, devices and systems that file uploads | |
US20200342439A1 (en) | Method, client device and pos terminal for offline transaction | |
CN104320703A (en) | Method, device and system for logging in intelligent television terminal | |
TR201810238T4 (en) | The appropriate authentication method and apparatus for the user using a mobile authentication application. | |
CN104113552A (en) | Platform authorization method, platform server side, application client side and system | |
CN105978994B (en) | A kind of login method of web oriented system | |
CN105897746A (en) | Cross-website login method, terminal and website server | |
CN110417724B (en) | Method, system, server and terminal for combined authentication of login states of application programs | |
CN102624687A (en) | Networking program user authentication method based on mobile terminal | |
CN104301875A (en) | Short message processing method and device | |
CN103414727A (en) | Encryption protection system for input password input box and using method thereof | |
CN108011872A (en) | Personal information intelligent acquisition method and system | |
CN104901951B (en) | Code data processing based on mobile terminal and exchange method in a kind of Web applications | |
CN107645481B (en) | Data processing method, system and device | |
US20160072776A1 (en) | Method and system for exchanging encrypted messages between computing devices in a communication network | |
JP2011221729A (en) | Id linking system | |
CN104506530B (en) | A kind of network data processing method and device, data transmission method for uplink and device | |
CN116076055A (en) | Method and system for verifying user identification | |
CN108768938A (en) | A kind of web data encryption and decryption method and device | |
CN110266641B (en) | Information reading method, system, device and computer readable storage medium | |
Rath et al. | Encryption-based second authentication factor solutions for qualified server-side signature creation | |
CN105141586A (en) | Method and system for verifying user |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
C10 | Entry into substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |