CN115129275A - Digital file printing method and device, electronic equipment and storage medium - Google Patents

Digital file printing method and device, electronic equipment and storage medium Download PDF

Info

Publication number
CN115129275A
CN115129275A CN202210752044.4A CN202210752044A CN115129275A CN 115129275 A CN115129275 A CN 115129275A CN 202210752044 A CN202210752044 A CN 202210752044A CN 115129275 A CN115129275 A CN 115129275A
Authority
CN
China
Prior art keywords
digital file
printing
file
digital
target digital
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
CN202210752044.4A
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.)
Ant Blockchain Technology Shanghai Co Ltd
Original Assignee
Ant Blockchain Technology Shanghai 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 Ant Blockchain Technology Shanghai Co Ltd filed Critical Ant Blockchain Technology Shanghai Co Ltd
Priority to CN202210752044.4A priority Critical patent/CN115129275A/en
Publication of CN115129275A publication Critical patent/CN115129275A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/12Digital output to print unit, e.g. line printer, chain printer
    • G06F3/1201Dedicated interfaces to print systems
    • G06F3/1202Dedicated interfaces to print systems specifically adapted to achieve a particular effect
    • G06F3/1203Improving or facilitating administration, e.g. print management
    • G06F3/1208Improving or facilitating administration, e.g. print management resulting in improved quality of the output result, e.g. print layout, colours, workflows, print preview
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F21/00Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
    • G06F21/10Protecting distributed programs or content, e.g. vending or licensing of copyrighted material ; Digital rights management [DRM]
    • G06F21/16Program or content traceability, e.g. by watermarking
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F21/00Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
    • G06F21/60Protecting data
    • G06F21/64Protecting data integrity, e.g. using checksums, certificates or signatures
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/12Digital output to print unit, e.g. line printer, chain printer
    • G06F3/1201Dedicated interfaces to print systems
    • G06F3/1223Dedicated interfaces to print systems specifically adapted to use a particular technique
    • G06F3/1237Print job management
    • G06F3/1242Image or content composition onto a page
    • G06F3/1243Variable data printing, e.g. document forms, templates, labels, coupons, advertisements, logos, watermarks, transactional printing, fixed content versioning
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/12Digital output to print unit, e.g. line printer, chain printer
    • G06F3/1201Dedicated interfaces to print systems
    • G06F3/1278Dedicated interfaces to print systems specifically adapted to adopt a particular infrastructure
    • G06F3/1285Remote printer device, e.g. being remote from client or server

Abstract

The embodiment of the specification provides a digital file printing method and device, electronic equipment and a storage medium. The method comprises the following steps: acquiring a printing request which is submitted by a first user and aims at a target digital file; responding to the printing request, calling digital watermark adding logic contained in an intelligent contract which is deployed in a block chain and used for printing management on the digital file, and adding the digital watermark to the target digital file; wherein the resolution of the digital watermark is greater than the copy resolution; in response to the addition of the digital watermark to the target digital file, further invoking a printing logic included in the intelligent contract, and storing the target digital file added with the digital watermark to a distributed ledger of the block chain, so that a printing device accessing the block chain acquires the target digital file added with the digital watermark from the distributed ledger, and performs printing processing on the acquired target digital file.

Description

Digital file printing method and device, electronic equipment and storage medium
Technical Field
One or more embodiments of the present disclosure relate to the field of block chain technologies, and in particular, to a method and an apparatus for printing a digital file, an electronic device, and a storage medium.
Background
With the development of the digital era, the way of processing various services by users is gradually changed from off-line to on-line.
For example, in application scenarios such as contract signing and proof opening, when performing offline processing, a user may generally perform signing processing such as signature and seal on a paper document to indicate that the signed paper document is a document original confirmed by the user; when the digital file is processed on line, a user can generally perform processing such as digital signature and electronic seal addition on the digital file, and the signed digital file is saved in a corresponding business system or is saved in local equipment by a related user.
Subsequently, if the user needs to provide the original paper version document corresponding to the signed digital document, the user can print the signed digital document and use the printed paper document as the original paper version document corresponding to the signed digital document.
Disclosure of Invention
The application provides a digital file printing method, which comprises the following steps:
acquiring a printing request which is submitted by a first user and aims at a target digital file;
responding to the printing request, calling digital watermark adding logic contained in an intelligent contract which is deployed in a block chain and used for printing management of the digital file, and adding the digital watermark to the target digital file; wherein the resolution of the digital watermark is greater than the copy resolution;
in response to the addition of the digital watermark to the target digital file, further invoking a printing logic included in the intelligent contract, and storing the target digital file added with the digital watermark to a distributed ledger of the block chain, so that a printing device accessing the block chain acquires the target digital file added with the digital watermark from the distributed ledger, and performs printing processing on the acquired target digital file.
Optionally, the print request includes print information related to the target digital file; the adding of the digital watermark to the target digital file includes:
and generating a digital image for the target digital file based on the printing information, and adding the generated digital image to the target digital file in a digital watermark form.
Optionally, the adding the digital watermark to the target digital file includes:
and acquiring a signature image corresponding to the digital seal of the first user, and adding the signature image to the target digital file in a digital watermark form.
Optionally, before invoking the printing logic included in the smart contract, the method further includes:
invoking an approval logic contained in the intelligent contract, and performing approval verification aiming at the first user;
and if the approval check is passed, further calling printing logic contained in the intelligent contract.
Optionally, the method further includes:
and if the approval and verification pass, generating a printing application record of the first user for the target digital file, and storing the generated printing application record to a distributed account book of the block chain.
Optionally, the storing the target digital file added with the digital watermark into a distributed ledger of the block chain, so that a printing device accessing the block chain acquires the target digital file added with the digital watermark from the distributed ledger, and performs printing processing on the acquired target digital file, includes:
generating an intelligent contract event corresponding to printing of the target digital file; wherein the smart contract event contains the target digital file to which the digital watermark is added;
storing the generated intelligent contract events into a distributed ledger of the blockchain, so that a printing device connected into the blockchain performs event monitoring on the intelligent contract events stored into the distributed ledger, and in response to the monitored intelligent contract events, performing printing processing on the target digital files contained in the intelligent contract events; or enabling a printing device accessing the blockchain to respond to the received intelligent contract event pushed by an event notification program loaded on a blockchain service platform or a node device in the blockchain, and performing printing processing on the target digital file contained in the intelligent contract event.
Optionally, the method further includes:
and generating a printing record of the first user for the target digital file, and storing the generated printing record to a distributed account book of the block chain.
Optionally, the method further includes:
acquiring a verification request submitted by a second user and used for carrying out validity verification on the printed target digital file; the verification request comprises digital information obtained by scanning a printed target digital file;
responding to the verification request, calling verification logic contained in the intelligent contract, and extracting the digital watermark added to the target digital file from the digital information;
and if the digital watermark is not extracted from the digital information, determining that the printed target digital file is an illegal file obtained by copying.
Optionally, before the digital watermark added to the target digital file is extracted from the digital information, the method further includes:
determining whether a print application record of the second user for the target digital file is stored in the blockchain;
if not, determining that the printed target digital file is an illegal file obtained by copying;
and if so, further extracting the digital watermark added to the target digital file from the digital information.
Optionally, before the digital watermark added to the target digital file is extracted from the digital information, the method further includes:
determining whether a print record of the second user for the target digital file is stored in the blockchain;
if not, determining that the printed target digital file is an illegal file obtained by copying;
and if so, further extracting the digital watermark added to the target digital file from the digital information.
Optionally, the print information includes one or more of the following:
a file identification of the target digital file;
device information of the printing device;
identity information of the first user;
a timestamp corresponding to a time of printing of the target digital file.
Optionally, the printing device accessing the block chain includes: and accessing an IoT printer of the blockchain by establishing an IoT (Internet of things) connection with a node device or a blockchain service platform in the blockchain.
The present application further provides a digital document printing apparatus, the apparatus comprising:
an acquisition unit configured to acquire a print request for a target digital file submitted by a first user;
the adding unit is used for responding to the printing request, calling digital watermark adding logic contained in an intelligent contract which is deployed in a block chain and used for printing management of the digital file, and adding the digital watermark to the target digital file; wherein the resolution of the digital watermark is greater than the copy resolution;
and the printing unit is used for responding to the addition of the digital watermark to the target digital file, further calling printing logic contained in the intelligent contract, storing the target digital file added with the digital watermark to a distributed account book of the block chain, so that a printing device accessed to the block chain acquires the target digital file added with the digital watermark from the distributed account book, and printing the acquired target digital file.
The application also provides an electronic device, which comprises a communication interface, a processor, a memory and a bus, wherein the communication interface, the processor and the memory are mutually connected through the bus;
the memory stores machine-readable instructions, and the processor executes the method by calling the machine-readable instructions.
The present application also provides a machine-readable storage medium having stored thereon machine-readable instructions which, when invoked and executed by a processor, implement the above-described method.
In the above embodiment, on one hand, in response to acquiring a print request submitted by a first user for a target digital file, a digital watermark may be added to the target digital file, and the resolution of the digital watermark is greater than the copy resolution; therefore, if the printing apparatus performs print processing for the target digital file to which the digital watermark is added, the digital watermark can be detected from a legal file resulting from printing; if the copy processing is performed on the legal document obtained by printing, the digital watermark cannot be detected from the illegal document obtained by copying, so that whether the paper document corresponding to the digital document is an original or a copy can be distinguished.
On the other hand, as an intelligent contract for printing management of a digital file is deployed in the blockchain, in response to acquiring a printing request for a target digital file submitted by a first user, digital watermark adding logic contained in the intelligent contract can be called, the digital watermark can be automatically added to the target digital file, and the target digital file added with the digital watermark is stored in a distributed book of the blockchain, so that a printing device can print the target digital file added with the digital watermark acquired from the chain; therefore, based on the characteristics of decentralized, non-traceable, traceable and the like of the block chain, the credibility, traceable and non-traceable of the digital watermark added to the target digital file can be ensured.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present disclosure, the drawings needed to be used in the description of the embodiments will be briefly introduced below, and it is obvious that the drawings in the following description are only some embodiments described in the present disclosure, and it is obvious for a person skilled in the art to obtain other drawings based on these drawings without inventive labor.
FIG. 1 is a schematic diagram of an application environment of a block chain-based digital file printing method in an embodiment of the present specification;
FIG. 2 is a schematic diagram of creating an intelligent contract and invoking the intelligent contract in one embodiment of the present description;
FIG. 3 is a flow chart of a digital document printing method in one embodiment of the present description;
fig. 4 is a schematic structural diagram of an electronic device in which the digital file printing apparatus is located in an embodiment of the present specification;
fig. 5 is a block diagram of a digital file printing apparatus in an embodiment of the present specification.
Detailed Description
In order to make those skilled in the art better understand the technical solutions in the present specification, the technical solutions in the embodiments of the present specification will be clearly and completely described below with reference to the drawings in the embodiments of the present specification, and it is obvious that the described embodiments are only a part of the embodiments of the present specification, and not all of the embodiments. All other embodiments obtained by a person of ordinary skill in the art based on the embodiments in the present specification without any creative effort shall fall within the protection scope of the present specification.
With the development of the digital age, the way of users processing various services gradually changes from off-line to on-line.
For example, in application scenarios such as contract signing and proof making, the user may generally perform signing processing such as signing, sealing and the like on a paper document to indicate that the signed paper document is a document original confirmed by the user when performing offline processing; when the digital file is processed on line, a user can generally perform processing such as digital signature and electronic seal addition on the digital file, and the signed digital file is saved in a corresponding business system or is saved in local equipment by a related user.
Subsequently, if the user needs to provide the original paper version document corresponding to the signed digital document, the user can print the signed digital document and use the printed paper document as the original paper version document corresponding to the signed digital document.
As can be seen, in the above illustrated embodiment, it is often difficult to distinguish whether an original is printed or a copy, that is, it is difficult to distinguish whether a legal original is printed, a non-original is copied, and even an illegal document is forged, for a paper document corresponding to a digital document provided by a user.
In view of this, the present specification aims to propose a technical solution for adding a digital watermark to a target digital file that needs to be subjected to a printing process, and the digital watermark added to the target digital file after printing is "lost" when the target digital file is copied.
When the method is implemented, a printing request which is submitted by a first user and aims at a target digital file can be obtained; further, in response to the print request, digital watermark adding logic included in an intelligent contract deployed in a block chain and used for performing print management on a digital file may be called to add a digital watermark to the target digital file, where the resolution of the digital watermark is greater than the copy resolution; further, a printing logic included in the intelligent contract may be called, and the target digital file added with the digital watermark is stored in the distributed ledger of the block chain, so that a printing device accessing the block chain acquires the target digital file added with the digital watermark from the distributed ledger, and performs printing processing on the acquired target digital file.
Therefore, in the technical solution in this specification, on one hand, in response to acquiring a print request for a target digital file submitted by a first user, a digital watermark may be added to the target digital file, and the resolution of the digital watermark is greater than the copy resolution; therefore, if the printing device performs printing processing for the target digital file to which the digital watermark is added, the digital watermark can be detected from a legal file resulting from printing; if the copy processing is performed on the legal document obtained by printing, the digital watermark cannot be detected from the illegal document obtained by copying, so that whether the paper document corresponding to the digital document is an original or a copy can be distinguished.
On the other hand, as an intelligent contract for printing management of a digital file is deployed in the blockchain, in response to acquiring a printing request for a target digital file submitted by a first user, digital watermark adding logic contained in the intelligent contract can be called, the digital watermark can be automatically added to the target digital file, and the target digital file added with the digital watermark is stored in a distributed book of the blockchain, so that a printing device can print the target digital file added with the digital watermark acquired from the chain; therefore, based on characteristics of decentralized, non-tampering, traceability and the like of the block chain, credibility, traceability and non-tampering of the digital watermark added to the target digital file can be ensured.
In order to make those skilled in the art better understand the technical solution in the embodiment of the present disclosure, a brief description will be given below of the related art of the block chain related to the embodiment of the present disclosure.
Current blockchain systems typically include two mainstream transaction models: an UTXO (un-spent Transaction Output) model represented by the bitcoin system; another is an account model represented by the Ethereum (Ethereum) system.
When the data storage is realized by adopting the block chain of the account model, the block chain data which needs to be stored and maintained by the node equipment of the block chain usually comprises the block data and account state data corresponding to the block chain accounts in the block chain; the tile data may further include tile header data, tile transaction data in the tile, and transaction receipts corresponding to the tile transaction data in the tile, etc.
When storing the various blockchain data shown above, the node device of the blockchain can organize the various blockchain data into a Merkle tree to be stored in a database in the form of key-value key value pairs. When the various blockchain data stored in the node device need to be queried, the data can be efficiently queried by traversing the Merkle tree by taking the keys of the various blockchain data as query indexes.
In such a blockchain model, an intelligent contract for data verification may be deployed on a blockchain, and a user may store data that needs to be verified as an account state of a contract account corresponding to the intelligent contract into a Merkle tree corresponding to the intelligent contract by calling the intelligent contract.
For example, in EtherFang, a special Merkle tree, called an MPT tree, is typically used to store and maintain blockchain data; for the account state data, an MPT state tree (commonly called world state) can be organized and stored in the database; the MPT state tree stores key-value key value pairs with account addresses as keys and account state data as values. The data content stored in the contract account corresponding to the intelligent contract is further organized into a storage tree (an MPT storage tree for storing data) to be stored in the database; filling the hash value of the root node of the storage tree into the MPT state tree as a part of account state data corresponding to the contract account; the hash of the root node of the MPT state tree is used as the authentication root and is further filled into the block header. When a user needs to perform data storage, the data needing storage can be used as account state data of a contract account corresponding to an intelligent contract in a mode of calling the intelligent contract and stored in a storage tree corresponding to the intelligent contract.
In the field of blockchain, an important concept is Account (Account); taking an etherhouse as an example, the etherhouse generally divides an account into two types, namely an external account and a contract account; the external account is an account directly controlled by the user and is also called as a user account; and a contract account is created by the user through an external account, an account containing contract code (i.e., a smart contract). Of course, for some blockchain models derived from the etherhouse-based architecture (such as ant blockchain), account types supported by the blockchain may be further expanded, which is not particularly limited in this specification.
For accounts in a blockchain, the account status of the account is usually maintained through a structure. When a transaction in a block is executed, the status of the account associated with the transaction in the block chain is also typically changed.
In one example, the structure of an account typically includes fields such as Balance, Nonce, Code, and Storage. Wherein:
a Balance field for maintaining the current account Balance of the account;
a Nonce field for maintaining a number of transactions for the account; the counter is used for guaranteeing that each transaction can be processed only once, and replay attack is effectively avoided;
a Code field for maintaining a contract Code for the account; in practical applications, only the hash value of the contract Code is typically maintained in the Code field; thus, the Code field is also commonly referred to as the Codhash field.
A Storage field for maintaining the Storage contents of the account (default field value is null); for a contract account, a separate storage space is usually allocated to store the storage content of the contract account; this separate storage space is often referred to as the account storage of the contract account.
The storage content of the contract account is usually constructed into a data structure of an MPT (Merkle Patricia Trie) tree and stored in the independent storage space; in which, the Storage content based on the contract account is constructed into an MPT tree, which is also commonly referred to as a Storage tree. Whereas the Storage field typically maintains only the root node of the Storage tree; thus, the Storage field is also commonly referred to as the Storage root field.
Wherein, for the external account, the field values of the Code field and the Storage field shown above are both null values.
Referring to fig. 1, fig. 1 is a schematic application environment diagram of a block chain-based pass authentication method according to an exemplary embodiment.
In a network environment as shown in fig. 1, may include a client-side computing device 101, a server-side 102, and at least one blockchain system; such as blockchain system 103, blockchain system 104, and blockchain system 105.
In one embodiment, the client-side computing device 101, may comprise a variety of different types of client-side computing devices; for example, the client-side computing devices may include devices such as PC terminal devices, mobile terminal devices, internet of things devices, and other forms of smart devices with certain computing capabilities, among others.
In one embodiment, at least some of the client-side computing devices 101 may be coupled to the server-side 102 through various communication networks; for example, device 1 and device 2 shown in fig. 1 are coupled to server side 102.
It will be appreciated that some of the client-side computing devices 101 may not be coupled to the server-side 102, but rather may be directly coupled to the blockchain system as blockchain nodes through various communication networks; for example, the apparatus 4 shown in fig. 1 may be coupled to the blockchain system as a blockchain link point.
Wherein, the communication network may comprise a wired and/or wireless communication network; for example, the Network may be a Local Area Network (LAN), a Wide Area Network (WAN), the internet, or a combination thereof, implemented based on a wired access Network or a wireless access Network provided by an operator, such as a mobile cellular Network.
In one embodiment, the client-side computing device 101, may also include one or more user-side servers; such as the device 5 shown in fig. 1. At least some of the client-side computing devices 101 may be coupled to the user-side server, which may be further coupled to the server 102; for example, devices 1 and 2 shown in fig. 1 are coupled to device 5, and device 5 is further coupled to server side 102.
In one embodiment, the server side 102 may also be coupled to one or more blockchain systems through various communication networks; for example, the server side 102 shown in fig. 1 may be coupled to the blockchain system 103, the blockchain system 104, and the blockchain system 105, respectively, and so on.
In one embodiment, each blockchain system may maintain one or more blockchains (e.g., public blockchains, private blockchains, federated blockchains, etc.) and include a plurality of blockchain nodes for carrying the one or more blockchains; for example, a block chain node 1, a block link point 2, a block link point 3, a block link point 4, a block link point i, etc., as shown in fig. 1, may collectively carry one or more block chains. And cross-chain data access can be performed among the blockchains contained in each blockchain system and among the blockchain systems.
In one embodiment, a block link point may be a physical device, or may be a virtual device implemented in a server or a server cluster; for example, the block-node device may be a physical host in a server cluster, or may be a virtual machine created after a hardware resource carried by a server or a server cluster is virtualized based on a virtualization technology. Each blockchain node may be coupled together by various types of communication methods (e.g., TCP/IP) to form a network to carry one or more blockchains.
In one embodiment, the server side 102 may include a BaaS platform (also referred to as BaaS cloud) for providing a Blockchain as a Service (BaaS). The BaaS platform can provide a pre-programmed software mode for activities (such as subscription and notification, user verification, database management and remote update) occurring on a block chain, and provide a block chain service which is simple and easy to use, one-key deployment, quick verification and flexible customization for client-side computing equipment coupled with the BaaS platform, so that the development, the test and the online of block chain service application can be accelerated, and the landing of block chain business application scenes of various industries can be assisted.
In one embodiment, the BaaS platform may also provide enterprise-level platform services based on blockchain technology to help enterprise-level customers construct a secure and stable blockchain environment and easily manage deployment, operation, maintenance, and development of blockchains.
It should be noted that, each time a latest block is generated in the blockchain, the corresponding status of the executed transactions in the blockchain changes after the transaction in the latest block is executed. For example, in a block chain constructed by an account model, the account status of an external account or a smart contract account usually changes correspondingly with the execution of a transaction.
For example, when a "transfer transaction" is completed in a block, the balances of the transferring party account and the transferring party account associated with the "transfer transaction" (i.e., the field values of the Balance fields of these accounts) are usually changed.
For another example, the "intelligent contract invocation transaction" in the block is used to invoke an intelligent contract deployed on the blockchain, invoke the intelligent contract in the EVM corresponding to the node device to execute the "intelligent contract invocation transaction", and update the account status of the intelligent contract account in the account of the intelligent contract after the execution of the intelligent contract invocation transaction.
In practical applications, whether public, private, or alliance, it is possible to provide the functionality of a Smart contract (Smart contract). An intelligent contract on a blockchain is a contract on a blockchain that can be executed triggered by a transaction. An intelligent contract may be defined in the form of code.
Taking an Etherhouse as an example, a user is supported to create and call some complex logic in the Etherhouse network. The ethernet workshop is used as a programmable block chain, and the core of the ethernet workshop is an ethernet workshop virtual machine (EVM), and each ethernet workshop node can run the EVM. The EVM is a well-behaved virtual machine through which various complex logic can be implemented. The user issuing and invoking smart contracts in the etherhouse is running on the EVM. In fact, the EVM directly runs virtual machine code (virtual machine bytecode, hereinafter referred to as "bytecode"), so the intelligent contract deployed on the blockchain may be bytecode.
Turning to FIG. 2, FIG. 2 is a diagram illustrating the creation of an intelligent contract and invocation of an intelligent contract in accordance with an exemplary embodiment.
An intelligent contract is created in an Ethernet workshop and needs to be subjected to the processes of compiling the intelligent contract, changing the intelligent contract into byte codes, deploying the intelligent contract to a block chain and the like. The intelligent contract is called in the Ethernet workshop, a transaction pointing to the intelligent contract address is initiated, the EVM of each node can respectively execute the transaction, and the intelligent contract code is distributed and operated in the virtual machine of each node in the Ethernet workshop network.
After the user sends a transaction containing the information of calling the intelligent contract to the Ethernet shop network, each node can execute the transaction in the EVM. The From field of the transaction is used for recording the address of the account initiating the calling of the intelligent contract, the To field is used for recording the address of the called intelligent contract, and the Data field of the transaction is used for recording the method and the parameter for calling the intelligent contract. After invoking the smart contract, the account status of the contract account may change. Subsequently, a client may check the account status of the contract account through the accessed block link points, for example, the account status may be stored in the Storage tree of the intelligent contract in the form of a Key-Value pair. The results of the execution of the transaction that invoked the smart contract may be stored in the MPT receipt tree in the form of a transaction receipt (receipt).
The intelligent contract can be independently executed at each node in the blockchain in a specified mode, and all execution records and data are stored on the blockchain, so that after the transaction is executed, transaction certificates which cannot be tampered and cannot be lost are stored on the blockchain.
The technical solution in this specification is described below by using specific embodiments and combining specific application scenarios.
Referring to fig. 3, fig. 3 is a flowchart of a digital file printing method according to an embodiment of the present disclosure. The digital file printing method can be applied to the application environment as shown in fig. 1 to realize the technical scheme of the specification. The digital file printing method can execute the following steps:
step 302: acquiring a printing request which is submitted by a first user and aims at a target digital file;
step 304: responding to the printing request, calling digital watermark adding logic contained in an intelligent contract which is deployed in a block chain and used for printing management of the digital file, and adding the digital watermark to the target digital file; wherein the resolution of the digital watermark is greater than the copy resolution;
step 306: in response to the addition of the digital watermark to the target digital file, further invoking a printing logic included in the intelligent contract, and storing the target digital file added with the digital watermark to a distributed ledger of the block chain, so that a printing device accessing the block chain acquires the target digital file added with the digital watermark from the distributed ledger, and performs printing processing on the acquired target digital file.
In this specification, the digital file printing method may be applied to a node device in a blockchain, and may also be applied to a blockchain service platform.
For example, the digital file printing method may be applied to a node device in a blockchain (such as any of the blockchain systems shown in fig. 1) to which a user's corresponding client-side computing device may be directly connected.
For another example, the digital file printing method may also be applied to a blockchain service platform (e.g., the server 102 shown in fig. 1), and a client-side computing device corresponding to a user may be connected to the blockchain service platform and interact with the blockchain system through the blockchain service platform.
In this specification, a print request for a target digital file submitted by a first user may be acquired.
The target digital file may be a digital file that the first user instructs a printing device to perform printing processing. The target digital file may be locally stored in a client-side computing device corresponding to the first user, may also be stored in a storage space of the blockchain service platform, may also be stored on the blockchain, and may also be stored in a third-party database, which is not limited in this specification.
The print request may be specifically in a form of an intelligent contract invoking transaction, or may be in a form of a request message.
For example, when a first user applies for print processing of a target digital file, if a client-side computing device corresponding to the first user is directly connected to a node device in a blockchain, the node device may receive a print request transaction initiated by the client-side computing device corresponding to the first user for the target digital file, where the print request transaction is used to invoke an intelligent contract deployed in the blockchain for print management of the digital file.
For another example, if the client-side computing device corresponding to the first user accesses the blockchain through the blockchain service platform, the blockchain service platform may receive a print request message for a target digital file sent by the client-side computing device corresponding to the first user.
In one illustrated embodiment, the print request may include print information associated with the target digital file.
For example, the print information related to the target digital file included in the print request may specifically include a combination of one or more of the following: a file identification of the target digital file; device information of the printing device; identity information of the first user; a timestamp corresponding to a time of printing of the target digital file.
The file identifier of the digital file can be used for uniquely identifying the digital file; for example, the file identification may specifically include, but is not limited to, a file ID of the digital file, a file name, a hash value of the file content, and the like.
The device information of the printing device may specifically include, but is not limited to, a device identifier of the printing device, address information of the printing device, and the like, where the device identifier may be used to uniquely identify the printing device; for example, the device information may specifically include, but is not limited to, a device ID, a MAC address, and the like of the printing device.
The identity information of the user can be used for identifying the user and also can be used for carrying out operations such as authentication and the like on the user; for example, the identity information may specifically include, but is not limited to, a user identifier, a public key corresponding to a private key held by the user, and the like.
The printing time corresponding to the digital file may be a time when the first user submits a printing request for the digital file, a time when the printing request is obtained, or other times that are set by a person skilled in the art as needed, and is not limited in this specification.
In this specification, in response to acquiring a print request for the target digital file submitted by the first user, digital watermark adding logic included in an intelligent contract that is deployed in a block chain and used for performing print management on the digital file may be called to add a digital watermark to the target digital file; wherein the resolution of the digital watermark is greater than the copy resolution.
Wherein, intelligent contracts used for printing management of digital files are deployed in the blockchain; and the digital watermarking logic contained in the intelligent contract is also the digital watermarking logic corresponding to the contract code contained in the intelligent contract.
Wherein, the copying resolution is the maximum resolution supported by the copying device; in general, since the copy resolution is designed with reference to the maximum resolution of the human eye, the copy resolution does not usually exceed 300 dpi. Specific values of the resolution of the digital watermark can be flexibly set by a person skilled in the art as required, and the specification is not particularly limited; for example, if the printing resolution of the printing apparatus is 1200dpi, the resolution of the digital watermark may be larger than the copy resolution and smaller than the printing resolution, that is, the resolution of the digital watermark may take any value in the interval of (300dpi, 1200 dpi).
It should be noted that, in this specification, in order to distinguish between a printed matter and a copy matter corresponding to a target digital file, the resolution of the digital watermark needs to be at least greater than the copy resolution; based on this, when the target digital file added with the digital watermark is printed and then further copied, the digital watermark is lost, so that the digital watermark cannot be detected from the copy, and then the printed matter and the copy can be distinguished.
For example, after acquiring a print request for a target digital file submitted by a first user, in response to the print request, digital watermark adding logic in an intelligent contract may be invoked to add a digital watermark to the target digital file, where the resolution of the digital watermark may be 600dpi, which is greater than the copy resolution of 300 dpi.
In practical applications, a digital watermark may be added to the target digital file based on the print information associated with the target digital file and/or the identity information of the first user.
In an embodiment shown, in a case that the print request includes print information related to the target digital file, the adding a digital watermark to the target digital file may specifically include: and generating a digital image for the target digital file based on the printing information, and adding the generated digital image to the target digital file in a digital watermark form.
For example, after a print request for a target digital file submitted by a first user is acquired, in response to the print request, digital watermarking logic in an intelligent contract may be invoked, a digital image is generated for the target digital file based on print information included in the print request, and the generated digital image is added to the target digital file in the form of a digital watermark.
In another embodiment shown, in a case that the print request includes the identity information of the first user, the adding a digital watermark to the target digital file may specifically include: and acquiring a signature image corresponding to the digital seal of the first user, and adding the signature image to the target digital file in a digital watermark form.
For example, after a print request for a target digital file submitted by a first user is acquired, in response to the print request, a digital watermark adding logic in an intelligent contract may be called, a signature image corresponding to a digital stamp of the first user is acquired based on identity information of the first user included in the print request, and the signature image is added to the target digital file in the form of a digital watermark.
In a possible embodiment, the block chain maintains an association relationship between the user identity information and the digital seal, and the digital seal of the first user maintained on the block chain may be directly invoked. In implementation, the process of obtaining the signature image corresponding to the digital seal of the first user may specifically include: and acquiring a signature image corresponding to the digital seal of the first user according to the identity information of the first user included in the printing request.
In another possible embodiment, a signature image of the first user may be generated temporarily. In this implementation, the process of obtaining the signature image corresponding to the digital seal of the first user may specifically include: generating a signature image for the first user based on the identity information of the first user included in the print request.
In another embodiment shown, in a case that the print request includes print information related to the target digital file and identity information of the first user, the process of adding a digital watermark to the target digital file may specifically include: and generating a digital image for the target digital file based on the identity information and the printing information, and adding the generated digital image to the target digital file in a digital watermark form.
For example, after a print request submitted by a first user for a target digital file is acquired, in response to the print request, digital watermarking logic in an intelligent contract may be invoked, a digital image is generated for the target digital file based on identity information of the first user included in the print request and print information included in the print request, and the generated digital image is added to the target digital file in the form of a digital watermark.
In a possible embodiment, the block chain maintains an association relationship between the user identity information and the digital seal, and the digital seal of the first user maintained on the block chain may be directly invoked. In implementation, the process of generating a digital image for the target digital file based on the identity information and the printing information, and adding the generated digital image to the target digital file in the form of a digital watermark may specifically include: acquiring a signature image corresponding to the digital seal of the first user according to the identity information of the first user included in the printing request; and adding the printing information included in the printing request to the signature image, and adding the signature image added with the printing information to the target digital file in a digital watermark form.
In another possible embodiment, a signature image of the first user may be generated temporarily. In implementation, the process of generating a digital image for the target digital file based on the identity information and the printing information, and adding the generated digital image to the target digital file in the form of a digital watermark may specifically include: and generating a signature image for the first user according to the identity information of the first user and the printing information included in the printing request, and adding the generated signature image to the target digital file in a digital watermark form.
In one or more embodiments shown above, in order to distinguish between a print and a copy based on the digital watermark added to the target digital file without affecting the printing effect of the target digital file, the digital watermark may specifically include a blind watermark; that is, the digital image, the signature image, and the like generated for the target digital file may be added to the target digital file in the form of a blind watermark.
The blind watermark can also be called as a hidden watermark, is a digital watermark mode invisible to human eyes, has strong concealment, and can protect the copyright of the carrier file without affecting the appearance of the carrier file. For a specific implementation manner of adding the blind watermark to the target digital file, please refer to the related art where not described in detail, and details are not described herein.
In an illustrated embodiment, in order to improve the printing security of a digital file, in response to acquiring a print request for the target digital file submitted by the first user, the print request may be approved, so as to ensure that the first user is a legal user having the printing authority of the target digital file. When implemented, before invoking print logic contained in an intelligent contract deployed in the blockchain for print management of digital files, the method may further include: invoking an approval logic contained in the intelligent contract, and performing approval verification aiming at the first user; and if the approval check passes, further calling printing logic contained in the intelligent contract.
The performing an approval check on the first user may specifically include, but is not limited to: verifying the signature of the digital signature of the first user based on a public key corresponding to a private key which is held by the first user and used for performing digital signature; and/or determining whether the first user is in a user list with the printing authority of the target digital file.
For example, after a print request for a target digital file submitted by a first user is acquired, in response to the print request, a digital watermark adding logic in an intelligent contract may be called first to add a digital watermark to the target digital file; further, in response to adding the digital watermark to the target digital file, the approval logic included in the smart contract may be invoked to perform approval verification for the first user; if the approval check is passed, printing logic contained in the intelligent contract can be further called, and the target digital file added with the digital watermark is stored in a distributed account book of the block chain.
For another example, after a print request for a target digital file submitted by a first user is acquired, in response to the print request, an approval logic included in the intelligent contract may be invoked first, and approval verification may be performed for the first user; if the approval verification is passed, further calling digital watermark adding logic in the intelligent contract to add digital watermark to the target digital file; further, in response to adding the digital watermark to the target digital file, print logic included in the smart contract may be invoked to store the target digital file with the digital watermark added to a distributed ledger of the blockchain.
It should be noted that, in the above-described embodiment, if the approval check for the first user fails, the print request for the target digital file submitted by the first user may be rejected, that is, the digital watermarking logic or the printing logic included in the smart contract does not need to be further invoked.
In one embodiment shown, in order to realize traceability of a printing process of a digital file, in response to acquiring a print request for the target digital file submitted by the first user, the print request may be recorded, so as to record that the first user has applied for printing for the target digital file. When implemented, the method may further comprise: and generating a printing application record of the first user for the target digital file, and storing the generated printing application record to a distributed account book of the block chain.
For example, after a print request for a target digital file submitted by a first user is acquired, in response to the print request, a digital watermark adding logic in an intelligent contract may be called first to add a digital watermark to the target digital file; further, in response to adding the digital watermark to the target digital file, the approval logic included in the smart contract may be invoked to perform approval verification for the first user; if the approval check is passed, generating a printing application record of the first user for the target digital file, and storing the generated printing application record to a distributed account book of the block chain; and further invoking printing logic contained in the intelligent contract, and storing the target digital file added with the digital watermark to a distributed account book of the block chain.
For another example, after a print request for a target digital file submitted by a first user is acquired, in response to the print request, a print application record for the target digital file by the first user may be generated first, and the generated print application record may be stored in a distributed ledger of the block chain, and an approval logic included in the smart contract may be invoked first, and an approval check may be performed on the first user; if the approval check is passed, further calling digital watermark adding logic and printing logic in an intelligent contract, adding a digital watermark to the target digital file, and storing the target digital file added with the digital watermark to a distributed account book of the block chain; if the approval check fails, the print request submitted by the first user for the target digital file may be denied.
As can be seen from the above, in the above embodiments, the print application record may be generated when the first user passes the approval check, or may be generated when the first user fails the approval check; in other words, the print application record may include a record corresponding to an accepted print request, or a record corresponding to a rejected print request, and those skilled in the art may flexibly set the record as needed, which is not limited in this specification. Correspondingly, according to different contents of the printing application record, the verification should be performed in different manners subsequently, and for a specific implementation manner of performing the verification on the printed target digital file according to the printing application record, please refer to the description of the relevant parts subsequently in this specification, which will not be described herein for the time being.
In this specification, in response to adding the digital watermark to the target digital file, further invoking a printing logic included in the smart contract, storing the target digital file to which the digital watermark is added to a distributed ledger of the blockchain, so that a printing device accessing the blockchain acquires the target digital file to which the digital watermark is added from the distributed ledger, and performs printing processing on the acquired target digital file.
The printing device accessing the block chain may specifically include: and an IoT printer accessing the block chain by establishing an IoT (Internet of Things) connection with node equipment or a block chain service platform in the block chain. The IoT connection may be a wired connection or a wireless connection, which is not limited in this specification.
For example, after a print request for a target digital file submitted by a first user is acquired, in response to the print request, digital watermark adding logic in an intelligent contract may be called to add a digital watermark to the target digital file, where the resolution of the digital watermark may be 600 dpi; further, printing logic included in the intelligent contract may be called, and the target digital file to which the digital watermark is added is stored in a distributed ledger of the blockchain; further, the printing device accessing the block chain may acquire the target digital file added with the digital watermark from the distributed ledger book, and may perform printing processing on the acquired target digital file added with the digital watermark, so as to obtain a legal file capable of detecting the digital watermark.
In one embodiment, since the printing device belongs to an off-chain device, the target digital file with the digital watermark added thereto can be acquired from the chain through an intelligent contract event mechanism or a prediction machine.
In implementation, the storing the target digital file added with the digital watermark into a distributed ledger of the block chain so that a printing device accessing the block chain acquires the target digital file added with the digital watermark from the distributed ledger and performs a printing process on the acquired target digital file may specifically include: generating an intelligent contract event corresponding to printing of the target digital file; wherein the smart contract event comprises the target digital file to which the digital watermark is added; storing the generated intelligent contract events to a distributed ledger of the blockchain, so that a printing device connected to the blockchain performs event monitoring on the intelligent contract events stored to the distributed ledger, and in response to the monitored intelligent contract events, performing printing processing on the target digital files contained in the intelligent contract events; or enabling a printing device accessing the blockchain to respond to the received intelligent contract event pushed by an event notification program loaded on a blockchain service platform or a node device in the blockchain, and performing printing processing on the target digital file contained in the intelligent contract event.
The event notification program may specifically include an SDK (Software Development Kit); the SDK may be configured to provide a subscription service for the smart contract events, that is, the SDK may monitor a new smart contract event generated after the smart contract deployed on the blockchain is invoked, and may push the monitored smart contract event to a corresponding user client.
For example, in response to adding the digital watermark to the target digital file, further invoking printing logic included in the intelligent contract, an intelligent contract event corresponding to printing of the target digital file may be generated, the intelligent contract event including the target digital file to which the digital watermark is added, and the generated intelligent contract event may be stored to a distributed ledger of the blockchain; subsequently, the printing device may actively perform event monitoring on the intelligent contract events stored in the distributed ledger of the blockchain, and perform printing processing on the target digital files included in the intelligent contract events in response to monitoring the intelligent contract events.
For another example, in response to adding the digital watermark to the target digital file, further invoking printing logic included in the smart contract, a smart contract event corresponding to printing of the target digital file may be generated, the smart contract event including the target digital file to which the digital watermark is added, and the generated smart contract event may be stored to a distributed ledger of the blockchain; subsequently, the printing device may subscribe, based on a publish/subscribe mode, to a node device of the blockchain or a blockchain service platform for a new intelligent contract event generated in the distributed ledger, and may further receive the intelligent contract event corresponding to printing of the target digital file, which is pushed to the printing device by the node device or the blockchain service platform; in response to receiving the intelligent contract event pushed by the blockchain service platform or an event notification program loaded on the node device, the printing device may perform printing processing on the target digital file included in the intelligent contract event.
It should be noted that, in the above illustrated embodiment, compared to an implementation manner in which the printing device actively monitors a new intelligent contract event in the distributed ledger of the blockchain, by performing event monitoring through an event notification program loaded on the blockchain service platform or a node device in the blockchain, the printing device only needs to receive the intelligent contract event pushed by the event notification program, and thus, the event monitoring cost of the printing device can be saved.
In addition, in the above-described embodiment, in response to acquiring an intelligent contract event corresponding to printing of the target digital file, the process of performing, by the printing device, print processing on the target digital file included in the intelligent contract event may specifically include: and analyzing the intelligent contract event into a printing instruction by a driving program carried by the printing equipment, issuing the analyzed printing instruction to the printing hardware at the bottom layer, and executing the printing instruction to print the target digital file.
In one embodiment shown, in order to realize traceability of the printing process of the digital file, a legal file printed by calling the printing logic included in the intelligent contract may be recorded, so as to perform subsequent validity check on the printed target digital file. When implemented, the method may further comprise: and generating a printing record of the first user for the target digital file, and storing the generated printing record to a distributed account book of the block chain.
For example, in response to adding the digital watermark to the target digital file, print logic included in the smart contract may be invoked, a print record for the target digital file may be generated by the first user, and the generated print record and the target digital file with the digital watermark added thereto may be stored to a distributed ledger for the blockchain.
In this specification, after adding a digital watermark to the target file in response to a print request for the target file submitted by the first user and performing print processing for the target digital file to which the digital watermark is added, it may be further determined whether the printed target file is an illegal file obtained by copying based on the digital watermark added to the target digital file in response to a check request for the printed target file submitted by a second user.
When implemented, the method may further comprise: acquiring a verification request submitted by a second user and used for carrying out validity verification on the printed target digital file; the verification request comprises digital information obtained by scanning a printed target digital file; responding to the verification request, calling verification logic contained in the intelligent contract, and extracting the digital watermark added to the target digital file from the digital information; and if the digital watermark is not extracted from the digital information, determining that the printed target digital file is an illegal file obtained by copying.
The first user and the second user may be the same user or different users, and the description is not limited in this specification; the "first user" and the "second user" are only used for distinguishing a user who requests to print the target digital file to obtain a legal file from a user who requests to perform validity check on the printed target digital file.
The printed target digital file is a paper file provided by the second user and required to be legally verified and corresponding to the target digital file.
The document scanning is performed on the printed target digital document, which means that a scanning device can perform lossless document scanning on the printed target digital document to obtain corresponding digital information; the lossless file scanning may be understood as that, if the printed target digital file is a legal file obtained by performing printing processing on the target digital file added with the digital watermark, at least digital information corresponding to the digital watermark may be obtained by scanning.
For example, when a second user needs to perform validity check on a printed target digital file, the second user may first perform file scanning on the printed target digital file to obtain corresponding digital information, and submit a check request for the printed target digital file to a node device in a blockchain or a blockchain service platform; further, in response to acquiring the verification request submitted by the second user, the node device or the block chain service platform may invoke verification logic included in the intelligent contract, and extract a digital watermark added to the target digital file from digital information obtained by performing file scanning on the printed target digital file included in the verification request; if the digital file is not extracted, the printed target digital file can be determined to be an illegal file obtained by copying; if the target digital file is extracted, the printed target digital file can be directly determined to be a legal file obtained by printing.
Alternatively, in the above-described embodiment, if the digital watermark added to the target digital file is extracted from the digital information included in the verification request, the extracted digital watermark may be analyzed to obtain generation information (such as printing information, user identity information, etc.) of the extracted digital watermark, and the generation information of the extracted digital watermark may be compared with the generation information stored on the block chain for generating the digital watermark added to the target digital file; if the target digital file is consistent with the target digital file, determining that the printed target digital file is a legal file obtained by printing; and if the digital files are inconsistent, determining that the printed target digital file is an illegal file obtained by counterfeiting or copying.
It should be noted that, in the above-described embodiment, since the resolution of the digital watermark added to the target digital file during printing is greater than the copy resolution, the digital watermark added to the target digital file cannot be detected from an illegal file obtained by copying, and thus it is possible to distinguish whether the paper file corresponding to the target digital file is a printed original or a copy.
In addition, in the printing process, the digital watermark is automatically added to the target digital file by calling the intelligent contract, and the target digital file added with the digital watermark is stored on the chain, so that in the subsequent validity check process, the generation information of the digital watermark can be further checked according to whether the digital watermark added to the target digital file can be detected from the printed target digital file, so that the validity check accuracy is improved, and the anti-counterfeiting effect of a printed piece of the digital file is improved.
In an embodiment shown, in order to avoid that the digital watermark detected in the printed target digital file is a forged digital watermark, it may be further determined whether the printed target digital file is an illegal file in combination with the print application record stored in the block chain, so as to improve the efficiency and accuracy of the validity check.
In implementation, before extracting the digital watermark added to the target digital file from the digital information, the method may further include: determining whether a print application record of the second user for the target digital file is stored in the blockchain; if not, determining that the printed target digital file is an illegal file obtained by copying; and if so, further extracting the digital watermark added to the target digital file from the digital information.
For example, in response to acquiring a verification request submitted by the second user for a printed target digital file, it may be determined whether a print application record of the second user for the target digital file is stored in the block chain; if the block chain does not store the printing application record of the second user for the target digital file, it indicates that the second user does not submit the printing request for the target digital file, so that the printed target digital file can be determined to be an illegal file obtained by copying (the second user copies legal files printed by other users), even an illegal file obtained by counterfeiting; if the block chain stores the print application record of the second user for the target digital file, it indicates that the second user has actually submitted a print request for the target digital file, so that the digital watermark added to the target digital file can be further extracted from the digital information.
In another embodiment shown, in order to further improve the efficiency and accuracy of validity check, it is avoided that the digital watermark detected in the printed target digital file is a forged digital watermark, and it is also possible to determine whether the printed target digital file is an illegal file by combining with the print record stored in the block chain.
In implementation, before extracting the digital watermark added to the target digital file from the digital information, the method may further include: determining whether a print record of the second user for the target digital file is stored in the blockchain; if not, determining that the printed target digital file is an illegal file obtained by copying; and if so, further extracting the digital watermark added to the target digital file from the digital information.
For example, in response to acquiring a verification request submitted by the second user for a printed target digital file, it may be determined whether a print record of the second user for the target digital file is stored in the block chain; if the block chain does not store the printing record of the second user for the target digital file, determining that the printed target digital file is an illegal file obtained by copying; if the block chain stores the print record of the second user for the target digital file, it indicates that the second user has actually submitted the print request for the target digital file, and the print request is accepted, so that the digital watermark added to the target digital file can be further extracted from the digital information.
For another example, in response to acquiring a verification request submitted by the second user for a printed target digital file, it may be determined whether a print application record of the second user for the target digital file is stored in the block chain; if the block chain stores the print application record of the second user for the target digital file, it may be further determined whether the block chain stores the print record of the second user for the target digital file; if the printing application record and the printing record are not stored, the second user does not submit a printing request aiming at the target digital file, and the printed target digital file can be determined to be an illegal file obtained by copying (the second user copies legal files obtained by printing of other users), even an illegal file obtained by counterfeiting; if the print application record is stored and the print record is not stored, it indicates that the second user may submit a print request for the target digital file, but the print request is rejected and actually does not perform print processing on the target digital file, so that the printed target digital file can be determined to be an illegal file obtained by copying (the second user copies a legal file printed by other users), even an illegal file obtained by forging.
As can be seen from the foregoing embodiments, on one hand, in response to acquiring a print request for a target digital file submitted by a first user, a digital watermark may be added to the target digital file, and the resolution of the digital watermark is greater than the copy resolution; therefore, if the printing apparatus performs print processing for the target digital file to which the digital watermark is added, the digital watermark can be detected from a legal file resulting from printing; if the copy processing is performed on the legal document obtained by printing, the digital watermark cannot be detected from the illegal document obtained by copying, so that whether the paper document corresponding to the digital document is an original or a copy can be distinguished.
On the other hand, as an intelligent contract used for printing management of the digital file is deployed in the block chain, in response to acquiring a printing request for the target digital file submitted by a first user, digital watermark adding logic included in the intelligent contract can be called, the digital watermark can be automatically added to the target digital file, and the target digital file added with the digital watermark is stored in a distributed account book of the block chain, so that the printing device can print the target digital file added with the digital watermark acquired from the chain; therefore, based on characteristics of decentralized, non-tampering, traceability and the like of the block chain, credibility, traceability and non-tampering of the digital watermark added to the target digital file can be ensured.
Corresponding to the embodiment of the digital file printing method, the specification also provides an embodiment of a digital file printing device.
Referring to fig. 4, fig. 4 is a schematic structural diagram of an electronic device in which a digital file printing apparatus is located in an embodiment of the present disclosure. At the hardware level, the device includes a processor 402, an internal bus 404, a network interface 406, a memory 408, and a non-volatile memory 410, although it may include hardware required for other services. One or more embodiments of the present description may be implemented in software, such as by processor 402 reading corresponding computer programs from non-volatile storage 410 into memory 408 and then executing. Of course, besides software implementation, the one or more embodiments in this specification do not exclude other implementations, such as logic devices or combinations of software and hardware, and so on, that is, the execution subject of the following processing flow is not limited to each logic unit, and may also be hardware or logic devices.
Referring to fig. 5, fig. 5 is a block diagram of a digital document printing apparatus according to an embodiment of the present disclosure. The digital file printing device can be applied to the electronic equipment shown in FIG. 4 to realize the technical scheme of the specification. Wherein the digital file printing apparatus may include:
an obtaining unit 502, configured to obtain a print request for a target digital file submitted by a first user;
an adding unit 504, configured to, in response to the print request, invoke a digital watermark adding logic included in an intelligent contract deployed in a block chain and used for performing print management on a digital file, and add a digital watermark to the target digital file; wherein the resolution of the digital watermark is greater than the copy resolution;
a printing unit 506, configured to, in response to adding the digital watermark to the target digital file, further invoke printing logic included in the smart contract, store the target digital file to which the digital watermark is added to a distributed ledger of the block chain, so that a printing device accessing the block chain acquires the target digital file to which the digital watermark is added from the distributed ledger, and perform printing processing on the acquired target digital file.
In this embodiment, the print request includes print information related to the target digital file; the adding unit 504 is specifically configured to:
and generating a digital image for the target digital file based on the printing information, and adding the generated digital image to the target digital file in a digital watermark form.
In this embodiment, the adding unit 504 is specifically configured to:
and acquiring a signature image corresponding to the digital seal of the first user, and adding the signature image to the target digital file in a digital watermark form.
In this embodiment, the apparatus further includes an approval unit, configured to:
invoking an approval logic contained in the intelligent contract, and performing approval verification aiming at the first user;
and if the approval check is passed, further calling printing logic contained in the intelligent contract.
In this embodiment, the apparatus further includes a first generating unit configured to:
and if the approval and verification pass, generating a printing application record of the first user for the target digital file, and storing the generated printing application record to a distributed account book of the block chain.
In this embodiment, the printing unit 506 is specifically configured to:
generating an intelligent contract event corresponding to printing of the target digital file; wherein the smart contract event contains the target digital file to which the digital watermark is added;
storing the generated intelligent contract events to a distributed ledger of the blockchain, so that a printing device connected to the blockchain performs event monitoring on the intelligent contract events stored to the distributed ledger, and in response to the monitored intelligent contract events, performing printing processing on the target digital files contained in the intelligent contract events; or enabling a printing device accessing the blockchain to respond to the received intelligent contract event pushed by an event notification program loaded on a blockchain service platform or a node device in the blockchain, and performing printing processing on the target digital file contained in the intelligent contract event.
In this embodiment, the apparatus further includes a second generating unit, configured to:
and generating a printing record of the first user for the target digital file, and storing the generated printing record to a distributed account book of the block chain.
In this embodiment, the apparatus further includes a verification unit, configured to:
acquiring a verification request submitted by a second user and used for carrying out validity verification on the printed target digital file; the verification request comprises digital information obtained by scanning a printed target digital file;
responding to the verification request, calling verification logic contained in the intelligent contract, and extracting the digital watermark added to the target digital file from the digital information;
and if the digital watermark is not extracted from the digital information, determining that the printed target digital file is an illegal file obtained by copying.
In this embodiment, the apparatus further includes a first determining unit configured to:
determining whether a print application record of the second user for the target digital file is stored in the blockchain;
if not, determining that the printed target digital file is an illegal file obtained by copying;
and if so, further extracting the digital watermark added to the target digital file from the digital information.
In this embodiment, the apparatus further includes a second determining unit configured to:
determining whether a print record of the second user for the target digital file is stored in the blockchain;
if not, determining that the printed target digital file is an illegal file obtained by copying;
and if so, further extracting the digital watermark added to the target digital file from the digital information.
In this embodiment, the print information includes one or more of the following:
a file identification of the target digital file;
device information of the printing device;
identity information of the first user;
a timestamp corresponding to a time of printing of the target digital file.
In this embodiment, the printing apparatus accessing the block chain includes: and the IoT printer accesses the blockchain by establishing an IoT connection with the node equipment or the blockchain service platform in the blockchain.
The implementation process of the functions and actions of each unit in the above device is specifically described in the implementation process of the corresponding step in the above method, and is not described herein again.
For the device embodiments, since they substantially correspond to the method embodiments, reference may be made to the partial description of the method embodiments for relevant points. The above-described embodiments of the apparatus are only illustrative, and the units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the modules can be selected according to actual needs to achieve the purpose of the solution in the specification. One of ordinary skill in the art can understand and implement it without inventive effort.
In the 90 s of the 20 th century, improvements in a technology could clearly distinguish between improvements in hardware (e.g., improvements in circuit structures such as diodes, transistors, switches, etc.) and improvements in software (improvements in process flow). However, as technology advances, many of today's process flow improvements have been seen as direct improvements in hardware circuit architecture. Designers almost always obtain the corresponding hardware circuit structure by programming an improved method flow into the hardware circuit. Thus, it cannot be said that an improvement in the process flow cannot be realized by hardware physical modules. For example, a Programmable Logic Device (PLD), such as a Field Programmable Gate Array (FPGA), is an integrated circuit whose Logic functions are determined by programming the Device by a user. A digital system is "integrated" on a PLD by the designer's own programming without requiring the chip manufacturer to design and fabricate application-specific integrated circuit chips. Furthermore, nowadays, instead of manually manufacturing an Integrated Circuit chip, such Programming is often implemented by "logic compiler" software, which is similar to the software compiler used in program development, but the original code before compiling is also written in a specific Programming Language, which is called Hardware Description Language (HDL), and the HDL is not only one kind but many kinds, such as abel (advanced boot Expression Language), ahdl (alternate Language Description Language), communication, CUPL (computer universal Programming Language), HDCal (Java Hardware Description Language), langa, Lola, mylar, HDL, PALASM, rhydl (runtime Description Language), vhjhdul (Hardware Description Language), and vhygl-Language, which are currently used commonly. It will also be apparent to those skilled in the art that hardware circuitry that implements the logical method flows can be readily obtained by merely slightly programming the method flows into an integrated circuit using the hardware description languages described above.
The controller may be implemented in any suitable manner, for example, the controller may take the form of, for example, a microprocessor or processor and a computer-readable medium storing computer-readable program code (e.g., software or firmware) executable by the (micro) processor, logic gates, switches, an Application Specific Integrated Circuit (ASIC), a programmable logic controller, and an embedded microcontroller, examples of which include, but are not limited to, the following microcontrollers: ARC 625D, Atmel AT91SAM, Microchip PIC18F26K20, and Silicone Labs C8051F320, the memory controller may also be implemented as part of the control logic of the memory. Those skilled in the art will also appreciate that, in addition to implementing the controller as pure computer readable program code, the same functionality can be implemented by logically programming method steps such that the controller is in the form of logic gates, switches, application specific integrated circuits, programmable logic controllers, embedded microcontrollers and the like. Such a controller may thus be considered a hardware component, and the means included therein for performing the various functions may also be considered as a structure within the hardware component. Or even means for performing the functions may be regarded as being both a software module for performing the method and a structure within a hardware component.
The systems, apparatuses, modules or units described in the above embodiments may be specifically implemented by a computer chip or an entity, or implemented by a product with certain functions. One typical implementation device is a server system. Of course, this application does not exclude that with future developments in computer technology, the computer implementing the functionality of the above described embodiments may be, for example, a personal computer, a laptop computer, a vehicle-mounted human-computer interaction device, a cellular phone, a camera phone, a smart phone, a personal digital assistant, a media player, a navigation device, an email device, a game console, a tablet computer, a wearable device or a combination of any of these devices.
Although one or more embodiments of the present description provide method operational steps as described in the embodiments or flowcharts, more or fewer operational steps may be included based on conventional or non-inventive approaches. The order of steps recited in the embodiments is merely one manner of performing the steps in a multitude of orders and does not represent the only order of execution. When implemented in an actual device or end product, can be executed sequentially or in parallel according to the methods shown in the embodiments or figures (e.g., parallel processor or multi-thread processing environments, even distributed data processing environments). The terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, the presence of additional identical or equivalent elements in a process, method, article, or apparatus that comprises the recited elements is not excluded. For example, the use of the terms first, second, etc. are used to denote names, but not to denote any particular order.
For convenience of description, the above devices are described as being divided into various modules by functions, and are described separately. Of course, when implementing one or more of the present description, the functions of each module may be implemented in one or more software and/or hardware, or a module implementing the same function may be implemented by a combination of multiple sub-modules or sub-units, etc. The above-described embodiments of the apparatus are merely illustrative, and for example, the division of the units is only one logical division, and other divisions may be realized in practice, for example, a plurality of units or components may be combined or integrated into another system, or some features may be omitted, or not executed. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection through some interfaces, devices or units, and may be in an electrical, mechanical or other form.
The present invention is described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the invention. It will be understood that each flow and/or block of the flow diagrams and/or block diagrams, and combinations of flows and/or blocks in the flow diagrams and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
In a typical configuration, a computing device includes one or more processors (CPUs), input/output interfaces, network interfaces, and memory.
The memory may include forms of volatile memory in a computer readable medium, Random Access Memory (RAM) and/or non-volatile memory, such as Read Only Memory (ROM) or flash memory (flash RAM). Memory is an example of a computer-readable medium.
Computer-readable media, including both non-transitory and non-transitory, removable and non-removable media, may implement information storage by any method or technology. The information may be computer readable instructions, data structures, modules of a program, or other data. Examples of computer storage media include, but are not limited to, phase change memory (PRAM), Static Random Access Memory (SRAM), Dynamic Random Access Memory (DRAM), other types of Random Access Memory (RAM), Read Only Memory (ROM), Electrically Erasable Programmable Read Only Memory (EEPROM), flash memory or other memory technology, compact disc read only memory (CD-ROM), Digital Versatile Discs (DVD) or other optical storage, magnetic cassettes, magnetic tape magnetic disk storage, graphene storage or other magnetic storage devices, or any other non-transmission medium that can be used to store information that can be accessed by a computing device. As defined herein, a computer readable medium does not include a transitory computer readable medium such as a modulated data signal and a carrier wave.
As will be appreciated by one skilled in the art, one or more embodiments of the present description may be provided as a method, system, or computer program product. Accordingly, one or more embodiments of the present description may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, one or more embodiments of the present description may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, and the like) having computer-usable program code embodied therein.
One or more embodiments of the present description may be described in the general context of computer-executable instructions, such as program modules, being executed by a computer. Generally, program modules include routines, programs, objects, components, data structures, etc. that perform particular tasks or implement particular abstract data types. One or more embodiments of the present specification can also be practiced in distributed computing environments where tasks are performed by remote processing devices that are linked through a communications network. In a distributed computing environment, program modules may be located in both local and remote computer storage media including memory storage devices.
All the embodiments in the present specification are described in a progressive manner, and the same and similar parts among the embodiments are referred to each other, and each embodiment focuses on the differences from other embodiments. In particular, for the system embodiment, since it is substantially similar to the method embodiment, the description is simple, and for the relevant points, reference may be made to the partial description of the method embodiment. In the description of the specification, reference to the description of the term "one embodiment," "some embodiments," "an example," "a specific example," or "some examples," etc., means that a particular feature, structure, material, or characteristic described in connection with the embodiment or example is included in at least one embodiment or example of the specification. In this specification, the schematic representations of the terms used above are not necessarily intended to refer to the same embodiment or example. Furthermore, the particular features, structures, materials, or characteristics described may be combined in any suitable manner in any one or more embodiments or examples. Furthermore, various embodiments or examples and features of different embodiments or examples described in this specification can be combined and combined by one skilled in the art without contradiction.
The above description is merely exemplary of one or more embodiments of the present disclosure and is not intended to limit the scope of one or more embodiments of the present disclosure. Various modifications and alterations to one or more embodiments described herein will be apparent to those skilled in the art. Any modification, equivalent replacement, improvement or the like made within the spirit and principle of the present specification should be included in the scope of the claims.

Claims (15)

1. A method of printing a digital document, the method comprising:
acquiring a printing request which is submitted by a first user and aims at a target digital file;
responding to the printing request, calling digital watermark adding logic contained in an intelligent contract which is deployed in a block chain and used for printing management of the digital file, and adding the digital watermark to the target digital file; wherein the resolution of the digital watermark is greater than the copy resolution;
in response to the addition of the digital watermark to the target digital file, further invoking a printing logic included in the intelligent contract, and storing the target digital file added with the digital watermark to a distributed ledger of the block chain, so that a printing device accessing the block chain acquires the target digital file added with the digital watermark from the distributed ledger, and performs printing processing on the acquired target digital file.
2. The method of claim 1, the print request including print information related to the target digital file;
the adding of the digital watermark to the target digital file includes:
and generating a digital image for the target digital file based on the printing information, and adding the generated digital image to the target digital file in a digital watermark form.
3. The method of claim 1, the adding a digital watermark to the target digital file, comprising:
and acquiring a signature image corresponding to the digital seal of the first user, and adding the signature image to the target digital file in a digital watermark form.
4. The method of claim 1, prior to invoking print logic contained in the smart contract, the method further comprising:
invoking an approval logic contained in the intelligent contract, and performing approval verification aiming at the first user;
and if the approval check is passed, further calling printing logic contained in the intelligent contract.
5. The method of claim 4, further comprising:
and if the approval and verification pass, generating a printing application record of the first user for the target digital file, and storing the generated printing application record to a distributed account book of the block chain.
6. The method according to claim 5, wherein the storing the target digital file added with the digital watermark to a distributed ledger of the blockchain, so that a printing device accessing the blockchain acquires the target digital file added with the digital watermark from the distributed ledger and performs printing processing on the acquired target digital file, comprises:
generating an intelligent contract event corresponding to printing of the target digital file; wherein the smart contract event contains the target digital file to which the digital watermark is added;
storing the generated intelligent contract events to a distributed ledger of the blockchain, so that a printing device connected to the blockchain performs event monitoring on the intelligent contract events stored to the distributed ledger, and in response to the monitored intelligent contract events, performing printing processing on the target digital files contained in the intelligent contract events; or enabling a printing device accessing the blockchain to respond to the received intelligent contract event pushed by an event notification program loaded on a blockchain service platform or a node device in the blockchain, and performing printing processing on the target digital file contained in the intelligent contract event.
7. The method of claim 6, further comprising:
and generating a printing record of the first user for the target digital file, and storing the generated printing record to a distributed account book of the block chain.
8. The method of claim 7, further comprising:
acquiring a verification request submitted by a second user and used for carrying out validity verification on the printed target digital file; the verification request comprises digital information obtained by scanning a printed target digital file;
responding to the verification request, calling verification logic contained in the intelligent contract, and extracting the digital watermark added to the target digital file from the digital information;
and if the digital watermark is not extracted from the digital information, determining that the printed target digital file is an illegal file obtained by copying.
9. The method of claim 8, prior to extracting the digital watermark added to the target digital file from the digital information, the method further comprising:
determining whether a print application record of the second user for the target digital file is stored in the blockchain;
if not, determining that the printed target digital file is an illegal file obtained by copying;
and if so, further extracting the digital watermark added to the target digital file from the digital information.
10. The method of claim 8, prior to extracting the digital watermark added to the target digital file from the digital information, the method further comprising:
determining whether a print record of the second user for the target digital file is stored in the blockchain;
if not, determining that the printed target digital file is an illegal file obtained by copying;
and if so, further extracting the digital watermark added to the target digital file from the digital information.
11. The method of claim 2, the print information comprising one or more of:
a file identification of the target digital file;
device information of the printing device;
identity information of the first user;
a timestamp corresponding to a time of printing of the target digital file.
12. The method of claim 1, the printing device accessing the blockchain, comprising: and the IoT printer accesses the blockchain by establishing an IoT connection with the node equipment or the blockchain service platform in the blockchain.
13. A digital document printing apparatus, said apparatus comprising:
the system comprises an acquisition unit, a processing unit and a processing unit, wherein the acquisition unit is used for acquiring a printing request which is submitted by a first user and aims at a target digital file;
the adding unit is used for responding to the printing request, calling digital watermark adding logic contained in an intelligent contract which is deployed in a block chain and used for printing management of the digital file, and adding the digital watermark to the target digital file; wherein the resolution of the digital watermark is greater than the copy resolution;
and the printing unit is used for responding to the addition of the digital watermark to the target digital file, further calling printing logic contained in the intelligent contract, storing the target digital file added with the digital watermark to a distributed account book of the block chain, so that a printing device accessed to the block chain acquires the target digital file added with the digital watermark from the distributed account book, and printing the acquired target digital file.
14. An electronic device comprises a communication interface, a processor, a memory and a bus, wherein the communication interface, the processor and the memory are connected with each other through the bus;
the memory has stored therein machine-readable instructions, which the processor executes by calling to perform the method of any one of claims 1 to 12.
15. A machine readable storage medium having stored thereon machine readable instructions which, when invoked and executed by a processor, carry out the method of any of claims 1 to 12.
CN202210752044.4A 2022-06-28 2022-06-28 Digital file printing method and device, electronic equipment and storage medium Pending CN115129275A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210752044.4A CN115129275A (en) 2022-06-28 2022-06-28 Digital file printing method and device, electronic equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210752044.4A CN115129275A (en) 2022-06-28 2022-06-28 Digital file printing method and device, electronic equipment and storage medium

Publications (1)

Publication Number Publication Date
CN115129275A true CN115129275A (en) 2022-09-30

Family

ID=83380622

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210752044.4A Pending CN115129275A (en) 2022-06-28 2022-06-28 Digital file printing method and device, electronic equipment and storage medium

Country Status (1)

Country Link
CN (1) CN115129275A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117336099A (en) * 2023-11-22 2024-01-02 成都天府通数字科技有限公司 Signing method and signing system for intelligent contract based on block chain technology

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117336099A (en) * 2023-11-22 2024-01-02 成都天府通数字科技有限公司 Signing method and signing system for intelligent contract based on block chain technology
CN117336099B (en) * 2023-11-22 2024-02-09 成都天府通数字科技有限公司 Signing method and signing system for intelligent contract based on block chain technology

Similar Documents

Publication Publication Date Title
US10904009B2 (en) Blockchain implementing delta storage
AU2020414467B2 (en) Partially-ordered blockchain
CN112287034B (en) Data synchronization method, equipment and computer readable storage medium
WO2021013499A1 (en) Security layer for configuring blockchain
CN112287033B (en) Data synchronization method, equipment and computer readable storage medium
US11070563B2 (en) Trace-based transaction validation and commitment
CN113169882A (en) System and method for block chain interoperability
US11816069B2 (en) Data deduplication in blockchain platforms
US11507535B2 (en) Probabilistic verification of linked data
KR20220160100A (en) Cross-Network Identity Provisioning
US11954094B2 (en) Database system public trust ledger architecture
CN114971827A (en) Account checking method and device based on block chain, electronic equipment and storage medium
KR20230073274A (en) Blockchain-Based Systems and Methods for Disclosure of Operating Systems
CN115130075A (en) Digital signature method and device, electronic equipment and storage medium
WO2022116761A1 (en) Self auditing blockchain
US11943360B2 (en) Generative cryptogram for blockchain data management
CN115129275A (en) Digital file printing method and device, electronic equipment and storage medium
US11550796B2 (en) Coexistence mediator for facilitating blockchain transactions
CN112015826B (en) Intelligent contract security detection method based on block chain and related equipment
US11782823B2 (en) Automatically capturing weather data during engineering tests
CN115129276A (en) Digital file printing method and device, electronic equipment and storage medium
CN115130148A (en) Data storage method and device, electronic equipment and storage medium
US20170286195A1 (en) Information object system
US11743327B2 (en) Topological ordering of blockchain associated proposals
CN114781004B (en) Block chain-based data evidence storage method and device, electronic equipment and storage medium

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