A data-sharing method comprising: starting data-sharing application on a first terminal, placing a file to be shared from the first terminal in a webpage of the data-sharing application and generating a link address for the file in the data-sharing application, broadcasting, by the data-sharing application on the first terminal, the link to at least one other terminal so that the at least one other terminal can share the file via the link address, the data-sharing application on the first terminal generating a first password string, transmitting the first password string to a file-receiving terminal, the first password string including a random number, an encrypted network address of the file-receiving terminal, and an encrypted link address of the file, the file-receiving terminal receiving the first password string, encrypting a local network address using the random number in the first password string, and generating a second password string based on the encrypted local network address and the first password string, the file receiving terminal transmitting, to the first terminal, the second password string to request the first terminal to transmit the file, the first terminal receiving the second password string returned from the file-receiving terminal, and the data-sharing application of the first terminal decrypting to obtain the local network address from the second password string, determining whether the local network address in the second password string is the same as the network address of the file-receiving terminal in the first password string, if they are determined to be the same, start transmitting the file to the file-receiving terminal. starting data-sharing application on a first terminal, placing a file to be shared from the first terminal in a webpage of the data-sharing application and generating a link address for the file in the data-sharing application, broadcasting, by the data-sharing application on the first terminal, the link to at least one other terminal so that the at least one other terminal can share the file via the link address, the data-sharing application on the first terminal generating a first password string, transmitting the first password string to a file-receiving terminal, the first password string including a random number, an encrypted network address of the file-receiving terminal, and an encrypted link address of the file, the file-receiving terminal receiving the first password string, encrypting a local network address using the random number in the first password string, and generating a second password string based on the encrypted local network address and the first password string, the file receiving terminal transmitting, to the first terminal, the second password string to request the first terminal to transmit the file, the first terminal receiving the second password string returned from the file-receiving terminal, and the data-sharing application of the first terminal decrypting to obtain the local network address from the second password string, determining whether the local network address in the second password string is the same as the network address of the file-receiving terminal in the first password string, if they are determined to be the same, start transmitting the file to the file-receiving terminal.