Communication device, computer program for a terminal device, and terminal device

The system securely and efficiently establishes wireless connections between communication devices and external devices by using network layer communications for key and authentication processes, addressing the limitations of existing methods and supporting diverse device capabilities.

JP7703892B2Active Publication Date: 2025-07-08BROTHER KOGYO KK
View PDF 4 Cites 0 Cited by

Patent Information

Application Number
JP2021076392
Authority / Receiving Office
JP · JP
Patent Type
Patents
Current Assignee / Owner
Filing Date
2021-04-28
Publication Date
2025-07-08
Estimated Expiration
2041-04-28

AI Technical Summary

Technical Problem

Existing techniques for establishing wireless connections between communication devices and external devices, such as printers and access points, lack security and efficiency, particularly in scenarios where devices do not support the Device Provisioning Protocol (DPP) method.

Method used

A communication device and terminal device system that utilizes the Wi-Fi standard to securely establish connections by transmitting and receiving public keys and authentication information through network layer communications, allowing for secure establishment of wireless connections using either the DPP or normal Wi-Fi methods based on device capabilities.

Benefits of technology

Ensures secure and efficient wireless connections by enabling secure key transmission and authentication, reducing user interaction, and minimizing disconnection risks, while accommodating devices with varying support for DPP and normal Wi-Fi methods.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure 0007703892000001
    Figure 0007703892000001
  • Figure 0007703892000002
    Figure 0007703892000002
  • Figure 0007703892000003
    Figure 0007703892000003
Patent Text Reader

Abstract

To provide a technique that can securely establish radio connection between a communication device and an external device.SOLUTION: A communication device comprises: a transmission request receiving unit that executes communication equal to or higher than a network layer of an OSI reference model to receive a transmission request from a terminal device; a public key transmission unit that, when the transmission request is received from the terminal device, executes communication equal to or higher than the network layer to transmit a public key to the terminal device; an authentication request receiving unit that, after the public key is transmitted to the terminal device, receives, from the terminal device, an authentication request in which the public key is used; an authentication response transmission unit that, when the authentication request is received from the terminal device, transmits a response to the terminal device; a first connection information receiving unit that, after the authentication response is transmitted to the terminal device, receives first connection information from the terminal device; and a second establishment unit that, when the first connection information is received from the terminal device, establishes second radio connection with an external device by using the first connection information.SELECTED DRAWING: Figure 5
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This specification discloses a technique for establishing a wireless connection between a communication device and an external device.

Background Art

[0002] Patent Document 1 discloses a technique for establishing a Wi-Fi connection between a printer and an access point (hereinafter referred to as "AP") using a terminal. In particular, a technique for establishing a Wi-Fi connection between a printer and an AP according to the DPP (abbreviation for Device Provisioning Protocol) method is disclosed. In this technique, the terminal acquires the respective public keys of the printer and the AP by reading a QR code (registered trademark) in which information including the public key is encoded, and uses these public keys to establish a Wi-Fi connection between the printer and the AP.

Prior Art Documents

Patent Documents

[0003]

Patent Document 1

Patent Document 2

Summary of the Invention

Problems to be Solved by the Invention

[0004] This specification provides a technique for securely establishing a wireless connection between a communication device and an external device.

Means for Solving the Problems

[0005] This specification discloses a communication device. The communication device includes: a first establishing unit that establishes a first wireless connection compliant with the Wi-Fi standard with a terminal device; a transmission request receiving unit that receives, from the terminal device, a transmission request for a public key of the communication device by performing communication above the network layer of the OSI (Open Systems Interconnection) reference model using the first wireless connection; a public key transmitting unit that transmits the public key to the terminal device by performing communication above the network layer using the first wireless connection when the transmission request is received from the terminal device; an authentication request receiving unit that receives, from the terminal device, an authentication request in which the public key is used and that complies with a predetermined method of the Wi-Fi standard after the public key is transmitted to the terminal device; an authentication response transmitting unit that transmits an authentication response compliant with the predetermined method to the terminal device when the authentication request is received from the terminal device; a first connection information receiving unit that receives, from the terminal device, first connection information compliant with the predetermined method after the authentication response is transmitted to the terminal device; and a second establishing unit that establishes a second wireless connection with an external device different from the terminal device using the first connection information when the first connection information is received from the terminal device.

[0006] According to the above configuration, the communication device receives a transmission request from the terminal device and transmits the public key to the terminal device by performing communication above the network layer of the OSI reference model. In this way, since the communication device performs communication above the network layer, it can securely transmit the public key to the terminal device. For this reason, a wireless connection can be securely established between the communication device and the external device.

[0007] The present specification also discloses a computer program for a terminal device. The computer program causes the computer of the terminal device to execute, by using a first wireless connection established between the terminal device and a communication device, which is a first wireless connection conforming to the Wi-Fi standard, communication at a network layer or higher of the OSI (Open Systems Interconnection) reference model, and transmit a public key transmission request to the communication device; when the transmission request is transmitted to the communication device, receive the public key from the communication device by using the first wireless connection and executing communication at a network layer or higher; and after receiving the public key from the communication device, execute first control processing for executing the wireless communication according to the predetermined method between the terminal device and the communication device, where the wireless communication according to the predetermined method includes an authentication request transmission process of transmitting an authentication request using the public key to the communication device, an authentication response reception process of receiving an authentication response from the communication device when the authentication request is transmitted to the communication device, and a first connection information transmission process of transmitting first connection information to the communication device after receiving the authentication response from the communication device, where the first connection information is information used by the communication device to establish a second wireless connection conforming to the Wi-Fi standard between the communication device and an external device different from the terminal device. The computer program may function as the first communication control unit including the first connection information transmission process.

[0008] According to the above configuration, the terminal device transmits a transmission request to the communication device and receives a public key from the communication device by executing communication at a network layer or higher of the OSI reference model. In this way, since the terminal device executes communication at a network layer or higher, it can securely receive the public key from the communication device. Therefore, a secure wireless connection can be established between the communication device and the external device.

[0009] The computer program for the above communication device, the computer-readable recording medium storing the computer program, and the method executed by the communication device are also novel and useful. Further, the computer-readable recording medium storing the computer program for the above terminal device, the terminal device realized by the computer program, and the method executed by the terminal device are also novel and useful. Further, the communication system including the above communication device and the terminal device realized by the above computer program is also novel and useful.

Brief Description of Drawings

[0010]

Figure 1

Figure 2

Figure 3

Figure 4

Figure 5

Figure 6

Figure 7

Figure 8

Figure 9

Figure 10

Figure 11

Figure 12

Modes for Carrying Out the Invention

[0011] (First Embodiment) (Configuration of Communication System 2; Figure 1) As shown in FIG. 1, the communication system 2 includes a plurality of terminals 10A and 10B, a plurality of printers 100A and 100B, and an AP (abbreviation for Access Point) 6. The technology of this embodiment is a technology for establishing a wireless connection (hereinafter referred to as "Wi-Fi connection") conforming to the Wi-Fi standard between a printer (e.g., 100A) and the AP 6 using a terminal (e.g., 10A).

[0012] (Configuration of Terminal 10A) The terminal 10A is a portable terminal device such as a mobile phone (e.g., a smartphone), a PDA, or a tablet PC. In a modified example, the terminal 10A may be a stationary PC, a notebook PC, or the like. The terminal 10A includes an operation unit 12A, a display unit 14A, a Wi-Fi interface 16A, a camera 18A, and a control unit 30A. Each unit 12A to 30A is connected to a bus line (reference numeral omitted). Hereinafter, an interface is referred to as "I / F".

[0013] The operation unit 12A includes a plurality of keys. The user can input various instructions to the terminal 10A by operating the operation unit 12. The display unit 14A is a display for displaying various information. The camera 18A is a device for photographing an object. In this embodiment, the camera 18A is used to photograph the QR code of the AP 6 and the QR code displayed on the printer (e.g., 100A).

[0014] Wi-Fi I / F 16A is a wireless I / F for performing Wi-Fi communication in accordance with the Wi-Fi standard. The Wi-Fi standard is a wireless communication standard for performing wireless communication in accordance with, for example, the 802.11 standard of IEEE (abbreviation for The Institute of Electrical and Electronics Engineers, Inc.) and standards equivalent thereto (such as 802.11a, 11b, 11g, 11n, 11ac, etc.). In particular, Wi-Fi I / F 16A supports the DPP (abbreviation for Device Provisioning Protocol) method established by the Wi-Fi Alliance. The details of the DPP method are described in the specification "Device Provisioning Protocol Specification Version 1.1.13" created by the Wi-Fi Alliance.

[0015] Wi-Fi I / F 16A further supports the WFD (abbreviation for Wi-Fi Direct (registered trademark)) method established by the Wi-Fi Alliance. The details of the WFD method are described in the specification "Wi-Fi Peer-to-Peer (P2P) Technical Specification Version 1.1" created by the Wi-Fi Alliance. In the WFD method, a Group Owner state (hereinafter referred to as "G / O state") and a client state (hereinafter referred to as "CL state") are defined. The G / O state is a state in which the device operates as an access point in a wireless connection established in accordance with the WFD method, and the CL state is a state in which the device operates as a station in the wireless connection. Hereinafter, the Wi-Fi connection established in accordance with the WFD method may be referred to as a "WFD connection".

[0016] In addition, the terminal 10A can establish a Wi-Fi connection with the AP6 according to a normal Wi-Fi method different from the DPP method and the WFD method (hereinafter, it may be described as "supporting the normal Wi-Fi method"). Specifically, in the normal Wi-Fi method, the terminal 10A can establish a Wi-Fi connection with the AP6 by using the SSID (abbreviation for Service Set Identifier) and password of the wireless network formed by the AP6. Hereinafter, the password will be referred to as "PW".

[0017] The control unit 30A includes a CPU 32A and a memory 34A. The CPU 32A executes various processes according to the programs 36A and 38A stored in the memory 34A. The memory 34A is composed of a volatile memory, a non-volatile memory, and the like.

[0018] The OS (abbreviation for Operating System) program 36A is a program for realizing the basic operations of the terminal 10A. The application 38A is a program for establishing a Wi-Fi connection between the terminal 10A and the AP6 or between a printer (e.g., 100A) and the AP6. Hereinafter, the OS program and the application will be referred to as "OS" and "app", respectively. The app 38A can establish a Wi-Fi connection between the terminal 10A and the AP6 or between a printer (e.g., 100A) and the AP6 by causing the OS 36A to execute processes according to the DPP method. The app 38A is installed on the terminal 10A, for example, from a server (not shown) on the Internet provided by the vendors of the printers 100A and 100B.

[0019] (Configuration of the terminal 10B) The terminal 10B is a portable terminal device such as a mobile phone (e.g., a smartphone), a PDA, or a tablet PC. In a modified example, the terminal 10B may be a stationary PC, a notebook PC, etc. The terminal 10B includes an operation unit 12B, a display unit 14B, a Wi-Fi I / F 16B, a camera 18B, and a control unit 30B. Each unit 12B to 30B is connected by a bus line (reference numerals omitted). The control unit 30B includes a CPU 32B and a memory 34B. The configuration of each unit 12B to 34B is the same as that of each unit 12A to 34A of the terminal 10A, except that the Wi-Fi I / F 16B does not support the DPP method. That is, the Wi-Fi I / F 16B supports the WFD method and the normal Wi-Fi method, but does not support the DPP method.

[0020] (Configuration of the printer 100A) The printer 100A is a peripheral device capable of executing a printing function (e.g., a peripheral device of the terminal 10A). In a modified example, the printer 100A may be a multifunction device capable of executing a scanning function, a FAX function, etc. in addition to the printing function. The printer 100A has a printer ID "AAA". The printer 100A includes an operation unit 112A, a display unit 114A, a Wi-Fi I / F 116A, a printing execution unit 118A, and a control unit 130A. Each unit 112A to 130A is connected by a bus line (reference numerals omitted).

[0021] The operation unit 112A includes a plurality of keys. The user can input various instructions to the printer 100A by operating the operation unit 112A. The display unit 114A is a display for displaying various information. The printing execution unit 118A includes a printing mechanism such as an inkjet method or a laser method. The Wi-Fi I / F 116A is the same as the Wi-Fi I / F 16A of the terminal 10A. That is, the Wi-Fi I / F 116A supports the DPP method, the WFD method, and the normal Wi-Fi method.

[0022] The control unit 130A includes a CPU 132A and a memory 134A. The CPU 132A executes various processes according to a program 136A stored in the memory 134A. The memory 134A is composed of a volatile memory, a non-volatile memory, etc. The memory 134A stores the MAC address 140A of the Wi-Fi I / F 116A.

[0023] (Configuration of Printer 100B) The printer 100B is a peripheral device (e.g., a peripheral device of the terminal 10A) capable of executing a printing function. In a modified example, the printer 100B may be a multifunctional device capable of executing a scan function, a FAX function, etc. in addition to the printing function. The printer 100B has a printer ID "BBB". The printer 100B includes an operation unit 112B, a display unit 114B, a Wi-Fi I / F 116B, a print execution unit 118B, and a control unit 130B. Each unit 112B to 130B is connected to a bus line (reference numerals omitted). The control unit 130B includes a CPU 132B and a memory 134B. The configuration of each unit 112B to 134B is the same as that of each unit 112A to 134A of the printer 100A, except that the Wi-Fi I / F 116B does not support the DPP method and the memory 134B stores the MAC address 140B of the Wi-Fi I / F 116B. That is, the Wi-Fi I / F 116B supports the WFD method and the normal Wi-Fi method, but does not support the DPP method.

[0024] (Configuration of AP6) The AP6 is not a device in the G / O state of WFD, but a normal access point called a wireless access point or a wireless LAN router. The AP6 supports the DPP method and the normal Wi-Fi method. The AP6 relays communication between a pair of devices belonging to a Wi-Fi network in which the AP6 operates as a parent station.

[0025] AP6 stores the public key PKap, the private key pkap, the MAC address 8 of its Wi-Fi I / F (not shown), the channel information CI1, the SSID "S1", and the PW "P1". The public key PKap and the private key pkap are used when performing authentication according to the DPP method. The channel information CI1 is information indicating one or more channels among a plurality of channels (in other words, the frequency width) available to AP6. A QR code obtained by encoding the public key PKap, the MAC address 8, and the channel information CI1 is attached to the housing of AP6. The SSID "S1" is information for identifying the Wi-Fi network formed by AP6. The PW "P1" is authentication information used when a device belongs to the Wi-Fi network.

[0026] (Establishment of Wi-Fi connection according to the DPP method between terminal 10A and AP6; Fig. 2) Subsequently, with reference to Fig. 2, the process for establishing a Wi-Fi connection according to the DPP method between terminal 10A and AP6 will be described. In the following description of Fig. 2, for ease of understanding, the operations executed by the CPUs (e.g., CPU32A, 132A, etc.) of each device are described mainly based on each device (e.g., terminal 10A, printer 100A, etc.) instead of mainly based on the CPU. Also, instead of describing mainly based on the terminal (e.g., terminal 10A), it may be described mainly based on the OS (e.g., OS36A) or the app (e.g., app 38A). Further, all communications executed by terminals 10A, 10B and printers 100A, 100B are executed via the Wi-Fi I / F 16A or the like. Therefore, in the following, when describing communication, the description "via the Wi-Fi I / F" will be omitted. The same applies to the description of Figs. 4 to 8.

[0027] In T10, app 38A receives an operation from the user to start app 38A. As a result, in T12, app 38A is started.

[0028] In T14, the application 38A receives a setup start operation from the user. The "setup" in this embodiment means establishing a Wi-Fi connection between the terminal 10A and the AP6, and then establishing a Wi-Fi connection between the printer and the AP6. When the application 38A receives the setup start operation, in T16, it activates the camera 18A. Then, in T18, the application 38A receives from the user an operation of photographing the QR code attached to the housing of the AP6 with the camera 18A.

[0029] In T19, the application 38A decodes the photographed QR code. As a result, the application 38A obtains the public key PKap, the MAC address 8, and the channel information CI1. The process of T19 corresponds to the Bootstrapping of the DPP method.

[0030] When the application 38A obtains the public key PKap, etc., in T20, it supplies a DPP start instruction to the OS 36A. The DPP start instruction includes the public key PKap, the MAC address MAC8, and the channel information CI1.

[0031] In T20, when the OS 36A obtains the DPP start instruction from the application 38A, in T22, it transmits an Authentication Request in which the public key PKap included in the DPP start instruction is used to the AP6 with the MAC address 8 included in the DPP start instruction as the destination. Hereinafter, Authentication will be described as "Auth" and Request will be described as "Req". Here, the OS 36A repeatedly transmits the Auth Req to the AP6 by sequentially using one or more channels indicated by the channel information CI1 included in the DPP start instruction. In this way, since the OS 36A transmits the Auth Req using the channels available to the AP6, the AP6 can appropriately receive the Auth Req.

[0032] The Auth Req is a signal that requests the execution of authentication for the source terminal 10A. Specifically, the OS 36A first generates a shared key using the private key of the terminal 10A (not shown) and the public key PKap of the AP6, and generates encrypted data by encrypting a random value using the shared key. Then, the OS 36A transmits an Auth Req including the public key of the terminal 10A (not shown), the encrypted data, and the Capability of the terminal 10A to the AP6. The Capability of the terminal 10A includes a value indicating that it can operate only as a DPP method Configurator.

[0033] In T22, when the AP6 receives the Auth Req from the terminal 10A, in T23, it executes the authentication of the encrypted data included in the Auth Req. Specifically, the AP6 generates a shared key using the public key of the terminal 10A included in the Auth Req and the private key pkap of the AP6, and decrypts the encrypted data using the shared key. When the decryption of the encrypted data is successful, the AP6 determines that the authentication is successful and executes the processing after T24.

[0034] In T24, the AP6 transmits an Auth Response including the Capability of the AP6 to the terminal 10A. Hereinafter, the Response is referred to as "Res". The Capability of the AP6 includes a value indicating that it can operate only as a DPP method Enrollee.

[0035] When OS36A receives an Auth Res from AP6 at T24, it determines that there is no conflict between the Capability of AP6 (i.e., Enrollee) included in the Auth Res and the Capability of terminal 10A itself (i.e., Configurator). Then, at T25, OS36A sends an Auth Confirm to AP6. The Auth Confirm contains information indicating that terminal 10A operates as a Configurator and AP6 operates as an Enrollee. As a result, at T26, OS36A decides to operate as a Configurator. A Configurator is a device responsible for sending a Configuration Object (hereinafter referred to as "CO") to an Enrollee, which will be described later.

[0036] Also, at T28, AP6 decides to operate as an Enrollee. An Enrollee is a device responsible for receiving a CO from a Configurator. The processes from T22 to T28 correspond to the Auth in the DPP method.

[0037] At T30, AP6 sends a Configuration Req to terminal 10A. Hereinafter, Configuration will be referred to as "Config". The Config Req is a signal requesting the transmission of a CO.

[0038] When OS36A receives a Config Req from AP6 at T30, it generates a CO for the AP. Specifically, OS36A first generates an AP - specific Signed Connector (hereinafter referred to as "SC"), which is information to be used by AP6 to establish a Wi - Fi connection. The AP - specific SC contains, for example, a group ID that is an identifier for identifying a wireless network. Then, OS36A generates a CO for the AP containing the AP - specific SC and, at T32, sends a Config Res containing the CO for the AP to AP6.

[0039] When AP6 receives Config Res from terminal 10A at T32, it sends Config Result to terminal 10A at T34. Config Result includes the code "STATUS_OK" indicating that the configuration was successful. The processes of T30 to T34 correspond to the DPP - style configuration.

[0040] Next, OS36A generates a terminal - specific SC, which is the information to be used by terminal 10A to establish a Wi - Fi connection. The terminal - specific SC includes the same group ID as the group ID included in the AP - specific SC. Then, at T40, OS36A sends a Discovery Req containing the terminal - specific SC to AP6. Discovery Req is a signal requesting the transmission of the other party's SC.

[0041] When AP6 receives Discovery Req from terminal 10A at T40, it uses the AP - specific SC to authenticate the terminal - specific SC included in Discovery Req. When the authentication of the terminal - specific SC is successful, AP6 generates a connection key. Then, at T42, AP6 sends a Discovery Res containing the AP - specific SC to terminal 10A.

[0042] When OS36A receives Discovery Res from AP6 at T42, it uses the terminal - specific SC to authenticate the AP - specific SC included in Discovery Res. When the authentication of the AP - specific SC is successful, OS36A generates a connection key. The connection key generated here is the same as the connection key generated by AP6. That is, the connection key is shared by terminal 10A and AP6. The processes of T40 and T42 correspond to the DPP - style network access.

[0043] Next, OS36A uses the connection key to perform 4-way-handshake communication with AP6. As a result, at T50, a Wi-Fi connection is established between terminal 10A and AP6. Thereby, a wireless network in which AP6 operates as the master station is formed, and terminal 10A belongs to the wireless network as a slave station.

[0044] Next, at T52, AP6 transmits a Status Query Result (hereinafter referred to as "Result") to terminal 10A. Result includes information indicating that the Wi-Fi connection between terminal 10A and AP6 has been established and the SSID "S1" of AP6.

[0045] At T52, OS36A obtains the SSID "S1" of AP6 by receiving Result from AP6.

[0046] (App processing; Figure 3) Subsequently, with reference to Figure 3, the processing executed by an app (for example, app 38A) installed on a terminal (for example, terminal 10A) will be described. The processing in Figure 3 is started triggered by the establishment of a WFD connection between the terminal and the printer in response to preprocessing being executed in the terminal and the printer. The preprocessing will be described later with reference to Figure 4. Hereinafter, the terminal and the printer for which the WFD connection is established will be referred to as the "target terminal" and the "target printer", respectively. Also, when explaining the processing in Figure 3, it will be mainly described with respect to the app installed on the target terminal (hereinafter referred to as the "target app") rather than the CPU of the target terminal.

[0047] In the initial state of FIG. 3, a Wi-Fi connection has been established between the target terminal and AP6. Here, the Wi-Fi connection established between the target terminal and AP6 is either a Wi-Fi connection according to the DPP method or a Wi-Fi connection according to the normal Wi-Fi method. When the target terminal has already established a Wi-Fi connection according to the DPP method with AP6, it has already stored the SSID "S1" of AP6 in the memory (see T52 in FIG. 2). Also, when the target terminal has already established a Wi-Fi connection according to the normal Wi-Fi method with AP6, it has already stored the SSID "S1" of AP6 in the memory. That is, when the target terminal has already established a Wi-Fi connection with AP6 according to either the DPP method or the normal Wi-Fi method, it has already stored the SSID "S1" of AP6 in the memory.

[0048] In S10, the target application causes the authentication screen SC1 to be displayed on the display unit of the target terminal. The authentication screen SC1 includes a message prompting the input of a username and PW for logging in to the target printer, a username input area, a PW input area, an OK button, and a cancel button. Hereinafter, the combination of the username and PW will be referred to as "user authentication information".

[0049] In S12, the target application accepts the input of user authentication information from the user. Specifically, after the target application accepts the input of the username and PW from the user on the authentication screen SC1, it accepts the selection of the OK button.

[0050] In S14, the target application uses the established WFD connection to transmit the user authentication information input in S12 to the target printer.

[0051] In S16, the target application determines whether user authentication has been successful. Specifically, first, in S14, in response to the transmission of user authentication information to the target printer, the target printer executes the authentication of the user authentication information. Authentication is successful when the user authentication information is stored in the target printer, and authentication fails when the user authentication information is not stored in the target printer. When the target application receives information indicating successful authentication from the target printer using an established WFD connection, it determines that user authentication has been successful (YES in S16) and proceeds to S20. On the other hand, when the target application receives information indicating failed authentication from the target printer using an established WFD connection, it determines that user authentication has failed (NO in S16) and ends the process in FIG. 3 without executing the processing after S20.

[0052] If a configuration is adopted in which the authentication of user authentication information is not executed, a third party who is not a legitimate user of the target printer can establish a Wi-Fi connection between the target printer and the AP. In this embodiment, since the processing after S20 is executed only when the authentication of user authentication information is successful, it is possible to suppress a third party from establishing a Wi-Fi connection between the target printer and the AP. As a result, the security of the target printer can be enhanced.

[0053] In S20, the target application determines whether the target terminal supports the DPP method. Specifically, the memory of the target terminal stores information (not shown in the figure) indicating whether the Wi-Fi I / F of the target terminal supports the DPP method. When the target application determines that the information indicating support for the DPP method is stored in the memory, it determines YES in S20 and proceeds to S22. On the other hand, when the target application determines that the information is not stored in the memory, it determines NO in S20 and proceeds to S60.

[0054] In S22, the target application determines whether various communications (i.e., T22 to T52 in FIG. 2) according to the DPP method have been executed between the target terminal and AP6. Specifically, when the target terminal's memory has stored information (e.g., AP use CO) indicating that various communications according to the DPP method have been executed between the target terminal and AP6, the target application determines YES in S22 and proceeds to S30. On the other hand, when the target application determines that the information is not stored in the memory, it determines NO in S22 and proceeds to S60.

[0055] In S30, the target application uses the WFD connection to send an inquiry to the target printer by performing communications above the network layer of the OSI (Open System Interconnection) reference model. The inquiry is a signal for inquiring whether the target printer supports the DPP method and for inquiring about the printer ID, capability information, and current status of the target printer. The capability information is information indicating capabilities (e.g., color printing, duplex printing, etc.) that the target printer can perform.

[0056] In S30, the target application further uses the WFD connection to receive a response from the target printer. The response includes information indicating whether the target printer supports the DPP method, the printer ID, the capability information, and the status.

[0057] In S32, the target application determines whether the target printer supports the DPP method. Specifically, when the target application receives a response including information indicating that the DPP method is supported, it determines YES in S32 and proceeds to S34. On the other hand, when the target application receives a response including information indicating that the DPP method is not supported, it determines NO in S32 and proceeds to S62.

[0058] In S34, the target application causes the confirmation screen SC2 to be displayed on the display unit of the target terminal. The confirmation screen SC2 is a screen for asking the user whether to execute processing for establishing a Wi-Fi connection between the target printer and AP6, and includes each piece of information received in S30 (i.e., printer ID, capability information, status), an OK button, and a cancel button. By viewing the confirmation screen SC2, the user can confirm information about the printer (i.e., the target printer) for which a Wi-Fi connection with AP6 should be established.

[0059] In S36, the target application determines whether the OK button in the confirmation screen SC2 has been selected or the cancel button has been selected. When the OK button is selected, the target application determines YES in S36 and proceeds to S40. When the cancel button is selected, the target application determines NO in S36 and ends the processing in FIG. 3 without executing the processing after S40.

[0060] In S40, the target application transmits a BS information transmission request to the target printer by performing communication above the network layer of the OSI reference model using the WFD connection. The BS information transmission request is a signal that requests the target printer to transmit BS information, which is information used in various communications (e.g., Auth) according to the DPP method.

[0061] In S42, the target application receives BS information from the target printer by performing communication above the network layer using the WFD connection. The BS information includes the public key of the target printer, the MAC address of the target printer, and channel information. For this purpose, the target printer can obtain the public key of the target printer. The processing in S40 and S42 corresponds to Bootstrapping of the DPP method.

[0062] In S44, the target application transmits a migration request to the target printer by using a WFD connection to execute communication above the network layer. The migration request is a signal that requests to change the state of the target printer from a DPP non-response state to a DPP response state. Here, the DPP non-response state is a state in which Auth Res cannot be transmitted, and the DPP response state is a state in which Auth Res can be transmitted. For this reason, the target printer can transmit Auth Res to the target terminal in response to receiving Auth Req from the target terminal. Also, the DPP response state is usually a state in which the processing load on the printer is higher than that in the DPP non-response state. Since the migration request is transmitted to the target printer at the timing when Auth is to be executed and the target printer changes to the DPP response state, the processing load on the target printer can be reduced.

[0063] In S50, the target application supplies a DPP start instruction to the OS of the target terminal. The DPP start instruction includes the BS information received in S42. When the DPP start instruction is acquired by the OS, various communications according to the DPP method are executed between the target terminal and the target printer, and between the target printer and AP6, and a Wi-Fi connection according to the DPP method is established between the target printer and AP6. When the processing of S50 ends, the processing of FIG. 3 ends.

[0064] Also, in S60, the target application transmits an inquiry to the target printer by using a WFD connection to execute communication above the network layer and receives a response from the target printer. The inquiry is the same as the inquiry transmitted in S30, except that it does not inquire whether the target printer supports the DPP method. Also, the response received in S60 is the same as the response received in S30, except that it does not include information indicating whether the target printer supports the DPP method.

[0065] In S62, the target application causes the confirmation screen SC2 to be displayed on the display unit of the target terminal. In S62 following S30, the target application causes the confirmation screen SC2 including each piece of information received in S30 (i.e., printer ID, capability information, status) to be displayed. In S62 following S60, the target application causes the confirmation screen SC2 including each piece of information received in S60 (i.e., printer ID, capability information, status) to be displayed.

[0066] In S64, the target application determines whether the OK button or the Cancel button within the confirmation screen SC2 has been selected. When the OK button is selected, the target application determines YES in S64 and proceeds to S66. When the Cancel button is selected, the target application determines NO in S64 and ends the processing of FIG. 3 without executing the processing after S66.

[0067] In S66, the target application obtains the SSID "S1" of AP6. Specifically, the target application supplies an SSID request to the OS of the target terminal and obtains the SSID "S1" of AP6 from the OS.

[0068] In S70, the target application causes the input screen SC3 to be displayed on the display unit of the target terminal. The input screen SC3 includes a message prompting for the input of the PW, the SSID "S1" obtained in S66, a PW input area, an OK button, and a Cancel button (see FIG. 6).

[0069] In S72, the target application determines whether the input of the PW has been received. Specifically, when the target application receives the input of the PW and the selection of the OK button on the input screen SC3, it determines YES in S72 and proceeds to S74. On the other hand, when the target application receives the selection of the Cancel button on the input screen SC3, it determines NO in S72 and ends the processing of FIG. 3 without executing the processing of S74.

[0070] In S74, the target application uses the WFD connection to send the SSID obtained in S66 and the PW input in S72 to the target printer. As a result, when the SSID and PW are used in the target printer, a Wi-Fi connection according to the normal Wi-Fi method is established between the target printer and AP6. When the process of S74 ends, the process of FIG. 3 ends.

[0071] (Case A-1; FIGS. 4 and 5) Subsequently, a specific case realized by the process of FIG. 3 will be described. First, with reference to FIGS. 4 and 5, a case A-1 of establishing a Wi-Fi connection between printer 100A and AP6 using terminal 10A in which a Wi-Fi connection according to the DPP method has already been established with AP6 will be described. In the initial state of FIG. 4, a Wi-Fi connection according to the DPP method has already been established between terminal 10A and AP6. That is, in the initial state of FIG. 4, in terminal 10A and AP6, the process of FIG. 2 has been executed, and AP6 has already stored the AP CO (see T32 in FIG. 2). In FIG. 4, first, preprocessing of T110 to T140 is executed.

[0072] In T110, printer 100A receives a setup start operation from the user. In this case, printer 100A shifts to the G / O state of the WFD method in T112. In the wireless network in which printer 100A operates as the G / O state, the SSID "S2" and the PW "P2" are used. In this way, since printer 100A shifts to the G / O state in response to receiving a setup start operation from the user, it can shift to the G / O state at the timing desired by the user.

[0073] In T114, printer 100A displays on display unit 114A a QR code obtained by encoding the SSID "S2" and the PW "P2".

[0074] The processing of T120 to T126 is the same as the processing of T10 to T16 in FIG. 2. Also, the processing of T128 is the same as the processing of T28 in FIG. 2, except that the QR code captured by the terminal 10A is the QR code displayed at T114.

[0075] At T130, the application 38A decodes the captured QR code. As a result, the application 38A obtains the SSID "S2" and the PW "P2".

[0076] At T132, the application 38A supplies a WFD connection instruction to the OS 36A. The WFD connection instruction includes the SSID "S2" and the PW "P2".

[0077] When the OS 36A obtains a WFD connection instruction from the application 38A at T132, it establishes a WFD connection with the printer 100A at T140. Specifically, the OS 36A executes various communications such as Authentication, Association, and 4way - handshake with the printer 100A. In the process of these various communications, authentication using the SSID "S2" and the PW "P2" is performed at the printer 100A, and when the authentication is successful, a WFD connection is established between the terminal 10A and the printer 100A. In this way, since the QR code in which the SSID "S2" and the PW "P2" are encoded is displayed by the printer 100A and the QR code is read by the terminal 10A, a WFD connection is properly established between the terminal 10A and the printer 100A. Although not shown in the figure, when a WFD connection is established between the terminal 10A and the printer 100A, information indicating that the WFD connection has been established is supplied from the OS 36A to the application 38A. Also, all the following communications using the WFD connection are communications above the network layer of the OSI reference model.

[0078] When the application 38A obtains information indicating that a WFD connection has been established from the OS 36A (the trigger for the processing in FIG. 3), it displays an authentication screen SC1 (see FIG. 3) at T142 (S10).

[0079] In T144, after the application 38A receives the input of the user ID "U1" and the PW "P3" from the user, it receives the selection of the OK button (S12). In this case, in T150, the application 38A uses the WFD connection to transmit the user authentication information including the input user ID "U1" and PW "P3" to the printer 100A (S14).

[0080] When the printer 100A receives the user authentication information from the terminal 10A in T150, it executes the authentication of the user authentication information. In this case, in T152, the printer 100A determines that the authentication is successful, and in T154, it uses the WFD connection to transmit the information indicating that the authentication is successful to the terminal 10A.

[0081] When the application 38A receives the information indicating that the authentication is successful from the printer 100A in T154 (YES in S16), since the terminal 10A supports the DPP method (YES in S20) and various communications according to the DPP method have been executed between the terminal 10A and the AP6 (YES in S22), in T160, it uses the WFD connection to transmit an inquiry to the printer 100A (S30).

[0082] When the printer 100A receives an inquiry from the terminal 10A in T160, in T162, it uses the WFD connection to transmit a response to the terminal 10A. The response includes information indicating that the printer 100A supports the DPP method and each information of the printer 100A (i.e., printer ID "AAA", capability information, status).

[0083] When the application 38A receives a response from the printer 100A in T162 (S30), it determines that the printer 100A supports the DPP method (YES in S32), and in T164, it displays the confirmation screen SC2 (see Figure 3) (S34). Then, in T166, the application 38A receives the selection of the OK button within the confirmation screen SC2 from the user (YES in S36).

[0084] (Continuation of FIG. 4; FIG. 5) In T170 of FIG. 5, the application 38A transmits a BS information transmission request to the printer 100A using the WFD connection (S40 in FIG. 3).

[0085] In T170, when the printer 100A receives a BS information transmission request from the terminal 10A, in T172, the printer 100A generates the public key PKpr and the private key pkpr of the printer 100A using the MAC address 140A of the printer 100A. For this purpose, the printer 100A does not need to store the public key PKpr and the private key pkpr before receiving the BS information transmission request from the terminal 10A. Then, in T174, the printer 100A transmits BS information including the public key PKpr, the MAC address 140A, and the channel information CI2 to the terminal 10A using the WFD connection. The channel information CI2 is information indicating one or more channels out of a plurality of channels (in other words, the frequency bandwidth) available to the printer 100A.

[0086] In T174, when the application 38A receives the BS information from the printer 100A (S42), in T176, the application 38A transmits a migration request to the printer 100A using the WFD connection (S44).

[0087] In T176, when the printer 100A receives a migration request from the terminal 10A, in T178, the printer 100A changes its state from the DPP non-response state to the DPP response state.

[0088] In T180, the application 38A supplies a DPP start instruction to the OS 36A (S50). The DPP start instruction includes the BS information.

[0089] The processing from T182 to T196 is the same as the processing from T22 to T42 in FIG. 2, except that the entity executing each process is different and the information used in each process is different. In particular, since OS36A transmits an Auth Req using a channel available to printer 100A, the printer 100A can appropriately receive the Auth Req. After the processing from T182 to T196, in T198, a Wi-Fi connection according to the DPP method is established between printer 100A and AP6. The processing of T199 is the same as the processing of T52, except that the entity executing the process is different.

[0090] By each of the above processes, both the terminal 10A and the printer 100A belong to the wireless network formed by AP6. Thereby, the printer 100A can receive print data from the terminal 10A via AP6 and execute printing according to the print data.

[0091] (Case A-2; FIG. 6) Subsequently, referring to FIG. 6, a case A-2 of establishing a Wi-Fi connection between printer 100A and AP6 using the terminal 10A in which a Wi-Fi connection according to the normal Wi-Fi method has been established with AP6 will be described. The initial state of FIG. 6 is the same as the initial state of FIG. 4, except that a Wi-Fi connection according to the normal Wi-Fi method has been established between the terminal 10A and AP6. That is, in the initial state of FIG. 6, the processing of FIG. 2 has not been executed, and a Wi-Fi connection using the SSID "S1" and PW "P1" has been established between the terminal 10A and AP6.

[0092] In FIG. 6, first, the same processing as T110 to T154 in FIG. 4 is executed. Then, when the application 38A receives information indicating that authentication has been successful from the printer 100A in T154 (YES in S16 of FIG. 3), the terminal 10A supports the DPP method (YES in S20), and various communications according to the DPP method have not been executed between the terminal 10A and AP6 (NO in S22), in T260, an inquiry is transmitted to the printer 100A using the WFD connection (S60).

[0093] When the printer 100A receives an inquiry from the terminal 10A at T260, at T262, it uses the WFD connection to send a response to the terminal 10A. The said response is the same as the response sent at T162 in FIG. 4, except that it does not include information indicating whether the printer 100A supports the DPP method. The processes of T264 and T266 are the same as the processes of T164 and T166.

[0094] The application 38A supplies an SSID request to the OS 36A at T270.

[0095] When the OS 36A obtains the SSID request from the application 36A at T270, at T272, it supplies the SSID "S1" of the AP6 to which the terminal 10A is currently establishing a Wi-Fi connection to the application 38A. As a result, the application 38A obtains the SSID "S1" of the AP6 (S66).

[0096] The application 38A displays the input screen SC3 at T274 (S70). The input screen SC3 includes the SSID "S1" acquired at T272.

[0097] After the application 38A accepts the input of the PW "P1" from the user at T276 and then accepts the selection of the OK button (YES at S72), in this case, the application 38A uses the WFD connection to send the SSID "S1" and the PW "P1" to the printer 100A at T278 (S74).

[0098] In T278, the printer 100A receives the SSID "S1" and PW "" from the terminal 10A. As a result, in T280, the printer 100A establishes a Wi-Fi connection with the AP6 according to the normal Wi-Fi method. Specifically, the printer 100A executes various communications such as Authentication, Association, and 4way-handshake with the AP6. In the process of these various communications, authentication using the SSID "S1" and PW "P1" is executed at the AP6, and when the authentication is successful, a Wi-Fi connection according to the normal Wi-Fi method is established between the printer 100A and the AP6. Also in this case, both the terminal 10A and the printer 100A can belong to the wireless network formed by the AP6.

[0099] (Case B; Figure 7) Subsequently, referring to Figure 7, a case B will be described in which a Wi-Fi connection is established between the printer 100A and the AP6 using the terminal 10B for which a Wi-Fi connection according to the normal Wi-Fi method has already been established with the AP6. The processes of T310 to T354 are the same as the processes of T110 to T154 in Figure 4.

[0100] When the application 38B receives information indicating that the authentication from the printer 100A has been successful in T354 (YES in S16 of Figure 3), since the terminal 10B does not support the DPP method (NO in S20), in T360, an inquiry is sent to the printer 100A (S60). The processes of T360 to T380 are the same as the processes of T260 to T280 in Figure 6. In this case, both the terminal 10B and the printer 100A can belong to the wireless network formed by the AP6.

[0101] (Case C; Figure 8) Next, referring to FIG. 8, a case C in which a Wi-Fi connection between the printer 100B and the AP6 is established using the terminal 10A that has already established a Wi-Fi connection with the AP6 according to the DPP method will be described. The processes of T410 to T460 are the same as the processes of T110 to T160 in FIG. 4, except that the SSID and PW used to establish a WFD connection between the terminal 10A and the printer 100B are the SSID "S4" and the PW "P4", respectively. Also, the process of T462 is the same as the process of T162, except that the response includes information indicating that the printer 100B does not support the DPP method and each piece of information of the printer 100B (i.e., printer ID "BBB", capability information, status).

[0102] When the application 38A receives a response from the printer 100B in T462 (S30), it determines that the printer 100B does not support the DPP method (NO in S32), and in T464, it displays the confirmation screen SC2 (S62). The processes of T466 to T480 are the same as the processes of T266 to T280 in FIG. 6. In this case, both the terminal 10A and the printer 100B can belong to the wireless network formed by the AP6.

[0103] (Effect of this embodiment) According to the above configuration, the terminal 10A can establish a Wi-Fi connection according to the DPP method between the printer 100A and the AP6 by performing various communications according to the DPP method (T182 to T196 in FIG. 5). Also, the terminal 10A can establish a Wi-Fi connection according to the normal Wi-Fi method between the printer 100B and the AP6 by performing various communications according to the normal Wi-Fi method with the printer 100B that does not support the DPP method. In this way, the terminal 10A can establish a Wi-Fi connection according to an appropriate method between each of the printers 100A and 100B and the AP6.

[0104] Also, by receiving the printer CO including the printer SC (T192 in FIG. 5), the printer 100A establishes a Wi-Fi connection with the AP6 according to the DPP method (T198). On the other hand, the printer 100A receives the SSID "S1" and PW "P1" of the wireless network formed by the AP6 from the terminal 10B that does not support the DPP method (T378 in FIG. 7), and establishes a Wi-Fi connection with the AP6 according to the normal Wi-Fi method (T380). In particular, the printer 100A receives the printer CO including the printer SC from the terminal 10A that supports the DPP method, and receives the SSID "S1" and PW "P1" from the terminal 10B that does not support the DPP method. In this way, the printer 100A can use the terminal 10A or 10B to establish a Wi-Fi connection with the AP6 according to an appropriate method.

[0105] In particular, the printer 100A can establish a Wi-Fi connection with the AP6 according to the DPP method (case A-1 in FIGS. 4 and 5) or can establish a Wi-Fi connection with the AP6 according to the normal Wi-Fi method (case A-2 in FIG. 6). And when the application 38A can establish a Wi-Fi connection according to the DPP method between the printer 100A and the AP6, it gives priority to establishing a Wi-Fi connection according to the DPP method (when YES in S32 in FIG. 3, execute S34 to S50). As described above, in the DPP method, the user does not need to input the PW. By giving priority to establishing a Wi-Fi connection according to the DPP method in this way, the operations that the user has to perform can be reduced, so the convenience of the user can be improved.

[0106] Also, assume a comparative example in which the user is prompted to perform various communications according to the DPP method between the terminal 10A and the AP6 when such communications have not been performed between the terminal 10A and the AP6. In this comparative example, various processes for establishing a Wi-Fi connection between the printer 100A and the AP6 are interrupted to perform various communications according to the DPP method between the terminal 10A and the AP6. Therefore, it takes a relatively long time to establish a Wi-Fi connection between the printer 100A and the AP6. On the other hand, in the present embodiment, when various communications according to the DPP method have not been performed between the terminal 10A and the AP6 (NO in S22 of FIG. 3), a Wi-Fi connection is established between the printer 100A and the AP6 according to the normal Wi-Fi method. Therefore, various processes for establishing a Wi-Fi connection between the printer 100A and the AP6 do not need to be interrupted as in the above comparative example, and thus a Wi-Fi connection can be established between the printer 100A and the AP6 relatively quickly.

[0107] Also, generally, the SSID "S1" of the AP6 can be changed by the administrator of the AP6, but the AP CO including the AP SC cannot be changed by the administrator. Therefore, in the Wi-Fi connection according to the DPP method, even if the SSID "S1" of the AP6 is changed by the administrator, the Wi-Fi connection established between the printer 100A and the AP6 is not disconnected. For this reason, by prioritizing the establishment of a Wi-Fi connection according to the DPP method, the possibility of the Wi-Fi connection between the printer 100A and the AP6 being disconnected can be reduced.

[0108] Also, assume a comparative example in which the QR code used to establish a Wi-Fi connection according to the DPP method between the printer 100A and the AP6 is different from the QR code used to establish a Wi-Fi connection according to the normal Wi-Fi method between the printer 100A and the AP6. In this comparative example, a user lacking knowledge of Wi-Fi connections may not know which QR code should be used to establish a Wi-Fi connection between the printer 100A and the AP6, and as a result, there is a possibility that a Wi-Fi connection cannot be established between the printer 100A and the AP6. On the other hand, in this embodiment, the user can establish a Wi-Fi connection between the printer 100A and the AP6 according to an appropriate method by photographing the same QR code (see T114 in FIG. 4) displayed on the printer 100A, whether in a situation where a Wi-Fi connection according to the DPP method should be established or in a situation where a Wi-Fi connection according to the normal Wi-Fi method should be established. Therefore, the convenience for the user is improved.

[0109] Also, the application 38A transmits a BS information transmission request to the printer 100A (S40 in FIG. 3, T170 in FIG. 5) by executing communication above the network layer of the OSI reference model, and receives BS information including the public key PKpr from the printer 100A (S42, T174). In this way, since the application 38A executes communication above the network layer, for example, compared with a configuration in which the public key PKpr is received by executing communication of a layer lower than the network layer such as Probe Req, the public key PKpr can be securely received. For this reason, a wireless connection can be securely established between the printer 100A and the AP6.

[0110] (Corresponding relationship) In Case A-1 and Case A-2, the printer 100A and the terminal 10A are examples of a "communication device" and a "terminal device", respectively. In Case B, the printer 100A and the terminal 10B are examples of a "communication device" and a "terminal device", respectively. In Case C, the printer 100B and the terminal 10A are examples of a "communication device" and a "terminal device", respectively. AP6 is an example of an "external device". The DPP method and the normal Wi-Fi method are examples of a "predetermined method" and a "different method", respectively. The public key PKpr of the printer 100A is an example of a "public key". The printer CO including the printer SC is an example of a "first connection information". The SSID "S2" and the PW "P2" of the wireless network in which the printer 100A operates as a G / O are examples of a "second connection information". The SSID "S1" and the PW "P1" of AP6 are examples of a "third connection information". The display unit 114A of the printer 100A is an example of an "output unit". The G / O state of the WFD method is an example of a "parent station state". The combination of the user ID "U1" and the PW "P3" is an example of a "user authentication information". The MAC address 140A of the printer 100A is an example of an "identification information". The printer ID, the capability information, and the status are examples of a "device information". The channel information CI2 is an example of a "channel information". The information indicating whether the DPP method is supported in the response is an example of an "availability information".

[0111] The WFD connection established at T140 in FIG. 4, the Wi-Fi connection established at T198 in FIG. 5, and the Wi-Fi connection established at T280 in FIG. 6 are examples of a "first wireless connection", a "second wireless connection", and a "third wireless connection", respectively. The setup start operation received at T110 in FIG. 4 is an example of an "establishment instruction". The BS information transmission request transmitted at T170 in FIG. 5 is an example of a "transmission request".

[0112] The processing of T110, T112, and T114 in FIG. 4 is an example of the processing executed by the "reception unit", "second transition unit", and "output control unit" of the "communication device", respectively. The processing of T140, T150, and T162 is an example of the processing executed by the "first establishment unit", "authentication information reception unit", and "device information transmission unit" of the "communication device", respectively. The processing of T170, T172, T174, T176, and T178 in FIG. 5 is an example of the processing executed by the "transmission request reception unit", "generation unit", "public key transmission unit (and channel information transmission unit)", "transition request reception unit", and "first transition unit" of the "communication device", respectively. The processing of T182, T184, T192, and T198 is an example of the processing executed by the "authentication request reception unit", "authentication response transmission unit", "first connection information reception unit", and "second establishment unit" of the "communication device", respectively. The processing of T378 and T380 in FIG. 7 is an example of the processing executed by the "second connection information reception unit" and "third establishment unit" of the "communication device", respectively.

[0113] The processing of S14 and S30 in FIG. 3 is an example of the processing executed by the "authentication information transmission unit" and "device information reception unit (and approval information reception unit)" of the "computer program", respectively. Also, the processing of S60 is an example of the processing executed by the "device information reception unit" of the "computer program". The processing of S34 and S62, S40, S42, and S44 is an example of the processing executed by the "display control unit", "transmission request transmission unit", "public key reception unit (and channel information reception unit)", and "transition request transmission unit" of the "computer program", respectively. The processing of S50 and S66 - S74 is an example of the processing executed by the "first communication control unit" and "second communication control unit" of the "computer program", respectively. In particular, the processing of S74 is an example of the "second connection information transmission process". The processing of T182, T184, and T192 in FIG. 5 is an example of the "authentication request transmission process", "authentication response reception process", and "first connection information transmission process" of the "terminal device", respectively.

[0114] (Second Embodiment) Next, a second embodiment will be described. The second embodiment differs from the first embodiment in that the process of S122 in FIG. 9 is executed instead of the process of S22 in FIG. 3, the specific process of S50 in FIG. 3 is different, and the specific process of S66 in FIG. 3 may be different.

[0115] (Application Processing; FIG. 9) Referring to FIG. 9, the process executed by the application of the second embodiment will be described. Note that in the initial state of FIG. 9, a Wi-Fi connection may not be established between the target terminal and the AP (for example, AP6).

[0116] When it is determined YES in S16 of FIG. 9, the target application determines in S122 whether a Wi-Fi connection has been established between the target terminal and AP6. Specifically, the memory of the target terminal stores flag information (not shown) indicating whether a Wi-Fi connection has been established between the target terminal and AP6. When the flag information indicating that a Wi-Fi connection has been established between the target terminal and AP6 is stored in the memory, the target application determines YES in S122 and proceeds to S20. On the other hand, when the flag information indicating that a Wi-Fi connection has not been established between the target terminal and AP6 is stored in the memory, the target application determines NO in S122 and proceeds to S60.

[0117] Note that when it is determined YES in S122, the target application determines whether the established Wi-Fi connection between the target terminal and AP6 is a Wi-Fi connection according to the DPP method or a Wi-Fi connection according to the normal Wi-Fi method, and stores the determination result. That is, it is determined whether various communications according to the DPP method have been executed between the target terminal and AP6, and the determination result is stored. The specific process is the same as the process of S22 in FIG. 3.

[0118] In S150, the target application supplies a DPP start instruction to the OS of the target terminal. The DPP start instruction includes, in addition to the BS information, information indicating whether the Wi-Fi connection established between the target terminal and AP6 is a Wi-Fi connection according to the DPP method or a Wi-Fi connection according to the normal Wi-Fi method (see S122). This information is used when Config is executed between the target terminal and the target printer.

[0119] Also, in S166 of FIG. 9, the specific processing differs depending on whether it passes through NO in S122 and whether it passes through NO in S20 or S32. The specific processing of S166 that passes through NO in S20 or S32 is the same as the processing of S66 in FIG. 2.

[0120] In S166 that passes through NO in S122, the target application broadcasts a Probe Req and obtains the SSID of the AP by receiving a Probe Res including the SSID of the AP from the APs existing around the target terminal. Note that when one or more SSIDs are obtained, the target application may display a selection screen for allowing the user to select one SSID from the one or more SSIDs on the display unit of the target terminal before executing the processing of S70. Then, in S70, the target application displays an input screen SC3 including one of the obtained SSIDs on the display unit of the target terminal. In a modified example, the target application may omit the processing of S166 when it passes through NO in S122. In this case, instead of the processing of S70, an input screen including an SSID input field, a PW input field, an OK button, and a cancel button may be displayed on the display unit of the target terminal. Then, in S72, when the selection of the OK button is received after accepting the input of the SSID and PW, in S74, the input SSID and PW may be transmitted to the target printer.

[0121] (Case D-1; FIG. 10) Next, a specific case executed by the process of FIG. 9 will be described. First, with reference to FIG. 10, a case D-1 in which a Wi-Fi connection between the printer 100A and the AP6 is established using the terminal 10A that has already established a Wi-Fi connection with the AP6 according to the DPP method will be described. FIG. 10 is a subsequent process of FIG. 4. That is, in case D-1, a Wi-Fi connection according to the DPP method has already been established between the terminal 10A and the AP6 (YES in S122 and YES in S20 of FIG. 9), and the printer 100A supports the DPP method (YES in S32).

[0122] First, in case D-1, the same processes as T170 to T178 in FIG. 5 are executed. After that, at T510, the application 38A supplies a DPP start instruction to the OS 36A (S150). The DPP start instruction includes BS information and information indicating that a Wi-Fi connection according to the DPP method has already been established between the terminal 10A and the AP6. After that, the same processes as T182 to T188 are executed.

[0123] In T520 to T524, the DPP method Config is executed. The processes of T520 to T524 are the same as the processes of T190 to T194 in FIG. 5. After that, the same processes as T195 to T199 in FIG. 5 are executed, and a Wi-Fi connection according to the DPP method is established between the printer 100A and the AP6. Also in this case, both the terminal 10A and the printer 100A can belong to the wireless network formed by the AP6.

[0124] (Case D-2; FIG. 10) Next, referring to FIG. 10, a case D-2 of establishing a Wi-Fi connection between the printer 100A and the AP6 will be described using the terminal 10A in which a Wi-Fi connection according to the normal Wi-Fi method has already been established with the AP6. In case D-2, a Wi-Fi connection (i.e., a Wi-Fi connection according to the normal Wi-Fi method) using the SSID "S1" and the PW "P1" has already been established between the terminal 10A and the AP6 (YES in S122), and the terminal 10A supports the DPP method (YES in S22), and the printer 100A supports the DPP method (YES in S32).

[0125] First, in case D-2, the processes of T110 to T166 in FIG. 4 and the same processes as T170 to T178 in FIG. 5 are executed. Thereafter, the application 38A supplies a DPP start instruction to the OS 36A at T530. The DPP start instruction includes the BS information and information indicating that a Wi-Fi connection according to the normal Wi-Fi method has already been established between the terminal 10A and the AP6. Thereafter, the same processes as T182 to T188 are executed.

[0126] In T540 to T544, the DPP method's Config is executed. The processes of T540 to T544 are the same as the processes of T190 to T194 in FIG. 5, except that the printer CO transmitted from the terminal 10A to the printer 100A at T542 includes the SSID "S1" and the PW "P1" of the AP6.

[0127] In T550, the printer 100A establishes a Wi-Fi connection with the AP6 according to the normal Wi-Fi method. Specifically, the printer 100A performs various communications such as Authentication, Association, and 4-way-handshake with the AP6. In the process of the various communications, authentication using the SSID "S1" and PW "P1" is performed at the AP6, and when the authentication is successful, a Wi-Fi connection according to the normal Wi-Fi method is established between the printer 100A and the AP6. The process of T552 is the same as that of T199. In this case as well, both the terminal 10A and the printer 100A can belong to the wireless network formed by the AP6. The printer CO including the SSID "S1" and PW "P1" of the AP6 is an example of the "first connection information".

[0128] (Case E; Figure 11) Subsequently, referring to Figure 11, a case E will be described in which a Wi-Fi connection is established between the printer 100A and the AP6 using the terminal 10A for which a Wi-Fi connection with the AP has not been established. In the initial state of Figure 11, a Wi-Fi connection has not been established between the terminal 10A and the AP6 (NO at S122).

[0129] First, in case E, the same processing as T110 to T154 in Figure 4 is executed. The processing of T660 to T666 is the same as the processing of T260 to T266 in Figure 6.

[0130] In T670, the application 38A broadcasts a Probe Req and receives a Probe Res from the AP6 at T672. The Probe Res includes the SSID "S1" of the AP6. The processing of T674 to T680 is the same as the processing of T274 to T280 in Figure 6. Thus, even in a situation where the terminal 10A has not established a Wi-Fi connection with the AP6, a Wi-Fi connection can be established between the printer 100A and the AP6.

[0131] (Effect of this embodiment) As described above, when the terminal 10A has already established a Wi-Fi connection with the AP6 (Case D-1 and Case D-2 in FIG. 10), the printer 100A receives the printer CO including the printer SC (or the SSID "S1" and PW "P1" of the AP6) (T522 (or T542 in FIG. 10 in FIG. 10)) to establish a Wi-Fi connection with the AP6 (T198 (or T550 in FIG. 5 referred to in FIG. 10)). On the other hand, when the terminal 10A has not yet established a Wi-Fi connection with the AP6 (Case E in FIG. 11), the printer 100A receives the SSID "S1" and PW "P1" of the wireless network formed by the AP6 from the terminal 10A (T678 in FIG. 11) to establish a Wi-Fi connection with the AP6 (T680). In this way, the printer 100A can appropriately establish a Wi-Fi connection with the AP6 according to the information received from the terminal 10A.

[0132] (Third Embodiment) Subsequently, the third embodiment will be described. In the third embodiment, the timings at which the processes of S30 and S32 in FIG. 3 are executed are different. Also, in the third embodiment, the process of S60 is not executed. Below, the description will focus on the points different from the first embodiment. Also, in FIG. 12, the same step numbers are assigned to the steps of the same processes as in the first embodiment, and the detailed description thereof is omitted.

[0133] (Processing of the Application; FIG. 12) Referring to FIG. 12, the processing executed by the application of the third embodiment will be described. When it is determined as YES in S16 in FIG. 12, the target application executes the processes of S30 and S32. The target application proceeds to S20 when it is determined as YES in S32, and proceeds to S62 when it is determined as NO in S32. Also, the target application proceeds to S62 when it is determined as NO in S20. Similarly, the target application proceeds to S62 when it is determined as NO in S22.

[0134] That is, in the third embodiment, prior to determining whether the terminal supports the DPP method, it is determined whether the printer supports the DPP method. Even in such a case, the terminal can establish a Wi-Fi connection according to an appropriate method between the printer and the AP.

[0135] As described above, specific examples of the technology disclosed in this specification have been described in detail, but these are merely examples and do not limit the scope of the claims. The technology described in the claims includes various modifications and changes of the specific examples exemplified above. Modifications of the above embodiments are listed below.

[0136] (Modification Example 1) Instead of migrating to the G / O of the WFD method at T112 in FIG. 4, the printer 100A may migrate to the parent station of the SoftAP. In this modification example, the process of migrating to the parent station of the SoftAP is an example of the process executed by the "second migration unit" of the "communication device". Further, in another modification example, in response to the printer 100A receiving a setup start operation, the terminal (for example, the terminal 10A) may display a QR code including information indicating that the terminal should be the parent station. Then, in response to the QR code being captured by the terminal 10A, the terminal 10A may migrate to the G / O state of the WFD method, and a WFD connection may be established between the terminal 10A and the printer 100A. In this modification example, the "output control unit" and the "second migration unit" of the "communication device" can be omitted. Generally speaking, for the "first wireless connection", the "communication device" may operate as the parent station, or the "terminal device" may operate as the parent station.

[0137] (Modification Example 2) The printer 100A may store the public key PKpr and the private key pkpr in advance from the shipping stage of the printer 100A. In this modification example, the "generation unit" of the "communication device" can be omitted.

[0138] (Modification Example 3) The public key PKpr does not have to be information obtained using the MAC address 140A of the printer 100A. For example, it may be information obtained using the serial number of the printer 100A, the printer ID, or the like. That is, the "identification information" may be any information for identifying the printer 100A. Further, in another modification example, the public key PKpr does not have to be information obtained using the "identification information".

[0139] (Modification Example 4) The printer 100A may always operate in the DPP response state. In this modification example, the "transition request receiving unit" and the "first transition unit" of the "communication device" can be omitted, and the "transition request transmitting unit" of the "computer program" can be omitted.

[0140] (Modification Example 5) In T174 of FIG. 5, the printer 100A may transmit BS information not including the channel information CI2 to the terminal 10A. For example, in T162 of FIG. 4, the printer 100A may transmit the channel information CI2 to the terminal 10A. That is, the timing of the processes executed by the "channel information transmitting unit" of the "communication device" and the "channel information receiving unit" of the "computer program" is not limited to the form of the above-described embodiment. Further, in another modification example, the printer 100A does not have to transmit the channel information CI2 to the terminal 10A. In this modification example, the "channel information transmitting unit" of the "communication device" can be omitted, and the "channel information receiving unit" of the "computer program" can be omitted.

[0141] (Modification Example 6) In T162 of FIG. 4, the printer 100A may transmit a response not including the printer ID "AAA", the capability information, and the status to the terminal 10A. In this modification example, the "device information transmitting unit" of the "communication device" can be omitted. Further, when it is determined as NO in S20 or NO in S22, the application 38 may omit the processes of S60 to S64 in FIG. 3 and proceed to the process of S66. In this modification example, the "device information transmitting unit" of the "communication device" can be omitted, and the "device information receiving unit" and the "display control unit" of the "computer program" can be omitted.

[0142] (Modification Example 7) The application 38A can omit the processes of S10 to S16 in FIG. 3. In this modification example, the "authentication information receiving unit" of the "communication device" can be omitted, and the "authentication information transmitting unit" of the "computer program" can be omitted.

[0143] (Modification Example 8) In FIG. 4 at T114, the printer 100A may cause the printing execution unit 118A to print a QR code in which the SSID "S2" and the PW "P2" are encoded. In this modification example, the printing execution unit 118A is an example of an "output unit", and the printing of the QR code is an example of a process executed by the "output control unit" of the "communication device". Also, in another modification example, at T114, the printer 100A may supply the SSID "S2" and the PW "P2" to an NFC (Near Field Communication) I / F. In this case, when the terminal (for example, the terminal 10A) is brought close to the printer 100A, the terminal acquires the SSID "S2" and the PW "P2". In this modification example, the NFC I / F is an example of an "output unit", and the supply of the SSID "S2" and the PW "P2" to the NFC I / F is an example of a process executed by the "output control unit" of the "communication device". Also, in another modification example, at T114, the printer 100A may supply the SSID "S2" and the PW "P2" to a BT (Bluetooth (registered trademark)) I / F. In this case, the terminal (for example, the terminal 10A) acquires the SSID "S2" and the PW "P2" via the BT I / F. In this modification example, the BT I / F is an example of an "output unit", and the supply of the SSID "S2" and the PW "P2" to the BT I / F is an example of a process executed by the "output control unit".

[0144] (Modification Example 9) In FIG. 4 at T110, the printer 100A may receive an access from a terminal (for example, the terminal 10A) to the printer 100A functioning as a web server, and receive a setup start operation from the terminal via the web server. In this modification example, receiving a setup start operation from the terminal via the web server is an example of a process executed by the "reception unit" of the "communication device".

[0145] (Modification Example 10) After the process of T354 in FIG. 7 is completed, the printer 100A may receive information from the terminal 10B indicating that the terminal 10B does not support the DPP method. Then, in response to the reception of the information, the printer 100A may display a notification screen notifying the user that Wi-Fi according to the DPP method cannot be established with the AP6. In this modification example, the "second connection information receiving unit" and the "third establishment unit" of the "communication device" can be omitted. Also, in another modification example, in T462 of FIG. 8, in response to the app 38A receiving a response including information indicating that the printer 100B does not support the DPP method, the app 38A may display a notification screen notifying the user that Wi-Fi according to the DPP method cannot be established between the printer 100B and the AP6. In this modification example, the "second communication control unit" of the "computer program" can be omitted. Also, in another modification example, in T162 of FIG. 4, the printer 100A may transmit a response not including information indicating that the printer 100A supports the DPP method to the terminal 10A. In this modification example, the "availability information receiving unit" of the "computer program" can be omitted.

[0146] (Modification Example 11) In the above-described embodiment, the processes of T182 to T194 in FIG. 5 were executed by the OS 36A of the terminal 10A. Instead, these various processes may be executed by the app 38A.

[0147] (Modification Example 12) The terminal 10A and the printer 100A may support a method different from the DPP method, and the printer 100A may execute various communications such as an authentication request, an authentication response, and first connection information between the terminal 10A and the printer 100A according to a method different from the DPP method. Generally speaking, the "predetermined method" is not limited to the DPP method.

[0148] (Modification Example 13) In each of the above-described embodiments, the processes in FIGS. 2 to 12 are realized by software (for example, OS 36A, 36B, apps 38A, 38B, programs 136A, 136B), but at least one of these processes may be realized by hardware such as a logic circuit.

[0149] The technical elements described in this specification or the drawings exhibit technical utility either individually or in various combinations, and are not limited to the combinations described in the claims at the time of filing. Also, the technologies exemplified in this specification or the drawings can achieve multiple objectives simultaneously, and achieving one of those objectives by itself has technical utility. The following items are elements described in the claims at the time of filing. (Item 1) A communication device, a first establishment unit that establishes a first wireless connection conforming to the Wi-Fi standard with a terminal device; a transmission request receiving unit that receives a transmission request for the public key of the communication device from the terminal device by performing communication above the network layer of the OSI (Open Systems Interconnection) reference model using the first wireless connection; a public key transmission unit that transmits the public key to the terminal device by performing communication above the network layer using the first wireless connection when the transmission request is received from the terminal device; an authentication request receiving unit that receives, from the terminal device, an authentication request in which the public key is used and that conforms to a predetermined method of the Wi-Fi standard after the public key is transmitted to the terminal device; an authentication response transmission unit that transmits an authentication response conforming to the predetermined method to the terminal device when the authentication request is received from the terminal device; a first connection information receiving unit that receives first connection information conforming to the predetermined method from the terminal device after the authentication response is transmitted to the terminal device; a second establishment unit that establishes a second wireless connection with an external device different from the terminal device using the first connection information when the first connection information is received from the terminal device; A communication device comprising the above. (Item 2) The communication device further comprises a generation unit that generates the public key when the transmission request is received from the terminal device, the communication device according to Item 1. (Item 3) The public key is information obtained using the identification information of the communication device, the communication device according to Item 1 or 2. (Item 4) The communication device further comprises a transition request receiving unit that receives a transition request for the state of the communication device from the terminal device using the first wireless connection; a first transition unit that transitions the state of the communication device from a non-response state to a response state when the transition request is received from the terminal device, where the non-response state is a state in which it is impossible to transmit the authentication response to the terminal device, and the response state is a state in which it is possible to transmit the authentication response to the terminal device, the communication device comprising the first transition unit. The authentication response transmission unit transmits the authentication response to the terminal device when the authentication request is received from the terminal device after the state of the communication device has shifted to the response state and the public key has been transmitted to the terminal device. The communication device according to any one of items 1 to 3. (Item 5) The communication device further includes a channel information transmission unit that transmits channel information indicating one or more wireless channels available to the communication device to the terminal device using the first wireless connection, The authentication request receiving unit receives the authentication request from the terminal device using one of the one or more wireless channels indicated by the channel information. The communication device according to any one of items 1 to 4. (Item 6) The communication device further includes a device information transmission unit that transmits device information related to the communication device to the terminal device using the first wireless connection, and when the device information is received by the terminal device, the device information is displayed on the display unit of the terminal device. The communication device according to any one of items 1 to 5, comprising the device information transmission unit. (Item 7) The communication device further includes an authentication information receiving unit that receives user authentication information from the terminal device using the first wireless connection, The second establishment unit establishes the second wireless connection with the external device when the authentication of the user authentication information is successful and the first connection information is received from the terminal device, When the authentication of the user authentication information fails, the second wireless connection is not established. The communication device according to any one of items 1 to 6. (Item 8) The first wireless connection is a wireless connection for the communication device to operate as a master station and the terminal device to operate as a slave station, The communication device further includes an output control unit that causes an output unit to output second connection information for establishing the first wireless connection, and when the second connection information is output, the second connection information is acquired by the terminal device. The communication device according to any one of items 1 to 7, comprising the output control unit. The first establishment unit establishes the first wireless connection with the terminal device when the second connection information is acquired by the terminal device. (Item 9) The communication device further includes a reception unit that receives an establishment instruction from a user to establish a wireless connection with the external device, When the establishment instruction is received, a second transition unit that transitions the state of the communication device from a non-parent station state that does not operate as the parent station to a parent station state that operates as the parent station, The communication device according to item 8, wherein the first establishment unit establishes the first wireless connection with the terminal device after the state of the communication device has transitioned to the parent station state. (Item 10) The transmission request receiving unit receives the transmission request from the terminal device when the terminal device supports the predetermined method. The communication device further includes When the terminal device does not support the predetermined method, without receiving the transmission request from the terminal device, using the first wireless connection, a second connection information receiving unit that receives third connection information from the terminal device according to a method different from the predetermined method of the Wi-Fi standard. When the third connection information is received from the terminal device, a third establishment unit that establishes a third wireless connection according to the Wi-Fi standard with the external device using the third connection information. The communication device according to any one of items 1 to 9, comprising (Item 11) The predetermined method is a DPP (abbreviation for Device Provisioning Protocol) method. The communication device according to any one of items 1 to 10, wherein the first connection information is a Configuration Object of the DPP method. (Item 12) A computer program for a terminal device, The computer program causes the computer of the terminal device to perform the following units, namely, A transmission request transmission unit that transmits a public key transmission request to the communication device by performing communication above the network layer of the OSI (Open Systems Interconnection) reference model using the first wireless connection established between the terminal device and the communication device, which is the first wireless connection according to the Wi-Fi standard. A public key receiving unit that receives the public key from the communication device by performing communication above the network layer using the first wireless connection when the transmission request is transmitted to the communication device. A first communication control unit that executes a first control process for performing wireless communication according to a predetermined method between the terminal device and the communication device after the public key is received from the communication device. The wireless communication according to the predetermined method is An authentication request transmission process for transmitting an authentication request using the public key to the communication device, An authentication response reception process for receiving an authentication response from the communication device when the authentication request is transmitted to the communication device, A first connection information transmission process for transmitting first connection information to the communication device after the authentication response is received from the communication device, where the first connection information is information used by the communication device to establish a second wireless connection according to the Wi-Fi standard between the communication device and an external device different from the terminal device, the first connection information transmission process, The first communication control unit including, A computer program that functions as. (Item 13) The computer program according to item 12, wherein the public key is information obtained using the identification information of the communication device. (Item 14) The computer program further causes the computer to, A migration request transmission unit that transmits a migration request to the communication device using the first wireless connection, where the migration request is a request to shift the state of the communication device from a non-response state to a response state, the non-response state is a state in which the authentication response cannot be transmitted to the terminal device, and the response state is a state in which the authentication response can be transmitted to the terminal device, function as the migration request transmission unit, The computer program according to item 12 or 13, wherein in the authentication response reception process, when the state of the communication device has shifted to the response state and the public key is received from the communication device, and then the authentication request is transmitted to the communication device, the authentication response is received from the communication device. (Item 15) The computer program further causes the computer to, Function as a channel information reception unit that receives channel information indicating one or more channels available to the communication device from the communication device using the first wireless connection, The computer program according to any one of items 12 to 14, wherein in the authentication request transmission process, the authentication request is transmitted to the communication device using one of the one or more wireless channels indicated by the channel information. (Item 16) The computer program further causes the computer to, A device information reception unit that receives device information related to the communication device from the communication device using the first wireless connection, A display control unit that causes the received device information to be displayed on a display unit of the terminal device; The computer program according to any one of items 12 to 15, which functions as (Item 17) The computer program further causes the computer to Function as an authentication information transmission unit that transmits user authentication information to the communication device using the first wireless connection; In the communication device, when the authentication of the user authentication information is successful and the first connection information is received from the terminal device, a second wireless connection is established between the communication device and the external device; The computer program according to any one of items 12 to 16, wherein in the communication device, when the authentication of the user authentication information fails, the second wireless connection is not established. (Item 18) The computer program further causes the computer to Function as an availability information receiving unit that receives, from the communication device, availability information indicating whether the communication device supports the predetermined method using the first wireless connection; The transmission request transmission unit transmits the transmission request to the communication device when the availability information indicates that the communication device supports the predetermined method; The computer program further causes the computer to When the availability information indicates that the communication device does not support the predetermined method, a second communication control unit that executes a second control process for performing wireless communication according to a method different from the predetermined method of the Wi-Fi standard between the terminal device and the communication device, The wireless communication according to the different method is A second connection information transmission process that transmits third connection information to the communication device using the first wireless connection without transmitting the transmission request to the communication device, wherein the third connection information is information used by the communication device to establish a third wireless connection according to the Wi-Fi standard between the communication device and the external device, the second connection information transmission process; The computer program according to any one of items 12 to 17, which functions as the second communication control unit including (Item 19) The predetermined method is the DPP (abbreviation for Device Provisioning Protocol) method. The first connection information is a computer program described in any one of items 12 to 18, which is a Configuration Object of the DPP method. (Item 20) A terminal device, a first establishment unit that establishes a first wireless connection compliant with the Wi-Fi standard with a communication device; a transmission request transmission unit that transmits a public key transmission request to the communication device by performing communication at a network layer or higher of the OSI (Open Systems Interconnection) reference model using the first wireless connection; a public key reception unit that receives the public key from the communication device by performing communication at a network layer or higher using the first wireless connection when the transmission request is transmitted to the communication device; an authentication request transmission unit that transmits an authentication request using the public key to the communication device after the public key is received from the communication device, the authentication request being in accordance with a predetermined method of the Wi-Fi standard; an authentication response reception unit that receives an authentication response in accordance with the predetermined method from the communication device when the authentication request is transmitted to the communication device; a first connection information transmission unit that transmits first connection information in accordance with the predetermined method to the communication device after the authentication response is received from the communication device, the first connection information being information used by the communication device to establish a second wireless connection compliant with the Wi-Fi standard between the communication device and an external device different from the terminal device; A terminal device comprising the above.

Explanation of Symbols

[0150] 2: Communication system, 6: AP, 8,140A,140B: MAC address, 10A,10B: Terminal, 12A,12B,112A,112B: Operation unit, 14A,14B,114A,114B: Display unit, 16A,16B,116A,116B: Wi-Fi I / F, 18A,18B: Camera, 30A,30B,130A,130B: Control unit, 32A,32B,132A,132B: CPU, 34A,34B,134A,134B: Memory, 36A,36B: OS program, 38A,38B: Application, 100A,100B: Printer, 118A,118B: Printing execution unit, 136A,136B: Program

Claims

1. A communication device, a first establishment unit that establishes a first wireless connection compliant with the Wi-Fi standard with a terminal device; a transmission request reception unit that receives a transmission request for the public key of the communication device from the terminal device by performing communication above the network layer of the OSI (Open Systems Interconnection) reference model using the first wireless connection; a public key transmission unit that transmits the public key to the terminal device by performing communication above the network layer using the first wireless connection when the transmission request is received from the terminal device; a transition request reception unit that receives a transition request for the state of the communication device from the terminal device using the first wireless connection; a first transition unit that transitions the state of the communication device from a non-response state to a response state when the transition request is received from the terminal device, where the non-response state is a state in which an authentication response cannot be transmitted to the terminal device, and the response state is a state in which the authentication response can be transmitted to the terminal device; an authentication request reception unit that receives, from the terminal device, an authentication request using the public key after the public key has been transmitted to the terminal device, the authentication request being in accordance with a predetermined method of the Wi-Fi standard; an authentication response transmission unit that transmits the authentication response in accordance with the predetermined method to the terminal device when the authentication request is received from the terminal device after the state of the communication device has been transitioned to the response state and the public key has been transmitted to the terminal device; a first connection information reception unit that receives first connection information in accordance with the predetermined method from the terminal device after the authentication response has been transmitted to the terminal device; a second establishment unit that establishes a second wireless connection with an external device different from the terminal device using the first connection information when the first connection information is received from the terminal device; A communication device comprising the above.

2. A communication device, a first establishment unit that establishes a first wireless connection compliant with the Wi-Fi standard with a terminal device; a transmission request reception unit that receives a transmission request for the public key of the communication device from the terminal device by performing communication above the network layer of the OSI (Open Systems Interconnection) reference model using the first wireless connection; When the transmission request is received from the terminal device, a public key transmission unit that transmits the public key to the terminal device by performing communication above the network layer using the first wireless connection; A channel information transmission unit that transmits channel information indicating one or more wireless channels available to the communication device to the terminal device using the first wireless connection; After the public key and the channel information are transmitted to the terminal device, an authentication request reception unit that receives, from the terminal device, an authentication request in which the public key is used and that conforms to a predetermined method of the Wi-Fi standard, using one of the one or more wireless channels indicated by the channel information; An authentication response transmission unit that transmits an authentication response conforming to the predetermined method to the terminal device when the authentication request is received from the terminal device; A first connection information reception unit that receives first connection information conforming to the predetermined method from the terminal device after the authentication response is transmitted to the terminal device; A second establishment unit that establishes a second wireless connection with an external device different from the terminal device using the first connection information when the first connection information is received from the terminal device; A communication device comprising the above.

3. A communication device, A first establishment unit that establishes a first wireless connection conforming to the Wi-Fi standard with a terminal device; An authentication information reception unit that receives user authentication information from the terminal device using the first wireless connection; A transmission request reception unit that receives, from the terminal device, a transmission request for the public key of the communication device by performing communication above the network layer of the OSI (Open Systems Interconnection) reference model using the first wireless connection; When the transmission request is received from the terminal device, a public key transmission unit that transmits the public key to the terminal device by performing communication above the network layer using the first wireless connection; After the public key is transmitted to the terminal device, an authentication request reception unit that receives, from the terminal device, an authentication request in which the public key is used and that conforms to a predetermined method of the Wi-Fi standard; An authentication response transmission unit that transmits an authentication response conforming to the predetermined method to the terminal device when the authentication request is received from the terminal device; After the authentication response is transmitted to the terminal device, a first connection information receiving unit that receives first connection information according to the predetermined method from the terminal device; A second establishing unit that establishes a second wireless connection with an external device different from the terminal device using the first connection information when the authentication of the user authentication information is successful and the first connection information is received from the terminal device, and when the authentication of the user authentication information fails, the second wireless connection is not established; the second establishing unit; A communication device comprising the same. **Claim 4** The communication device further comprises When the transmission request is received from the terminal device, a generation unit that generates the public key, the communication device according to any one of claims 1 to 3. **Claim 5** The public key is information obtained using the identification information of the communication device, the communication device according to any one of claims 1 to 4. **Claim 6** The communication device further comprises A device information transmitting unit that transmits device information related to the communication device to the terminal device using the first wireless connection, and when the device information is received by the terminal device, the device information is displayed on the display unit of the terminal device; the communication device according to any one of claims 1 to 5 comprising the device information transmitting unit. **Claim 7** The first wireless connection is a wireless connection for the communication device to operate as a master station and the terminal device to operate as a slave station, The communication device further comprises An output control unit that causes an output unit to output second connection information for establishing the first wireless connection, and when the second connection information is output, the second connection information is acquired by the terminal device; comprising the output control unit, The first establishing unit establishes the first wireless connection with the terminal device when the second connection information is acquired by the terminal device, the communication device according to any one of claims 1 to 6. **Claim 8** The communication device further comprises A reception unit that receives an establishment instruction from the user for establishing a wireless connection with the external device, and A second transition unit that, when the establishment instruction is received, transitions the state of the communication device from a non-master station state in which it does not operate as a master station to a master station state in which it operates as a master station, and The first establishing unit establishes the first wireless connection with the terminal device after the state of the communication device is transitioned to the master station state, the communication device according to claim 7.

9. When the transmission request receiving unit receives the transmission request from the terminal device when the terminal device supports the predetermined method, The communication device further includes When the terminal device does not support the predetermined method, without receiving the transmission request from the terminal device, using the first wireless connection, from the terminal device, a second connection information receiving unit that receives third connection information according to a method different from the predetermined method of the Wi-Fi standard; When the third connection information is received from the terminal device, a third establishing unit that uses the third connection information to establish a third wireless connection according to the Wi-Fi standard with the external device; The communication device according to any one of claims 1 to 8, comprising:

10. The predetermined method is a DPP (abbreviation for Device Provisioning Protocol) method, The communication device according to any one of claims 1 to 9, wherein the first connection information is a Configuration Object of the DPP method.

11. A computer program for a terminal device, The computer program causes the computer of the terminal device to perform the following units, namely, A first wireless connection established between the terminal device and the communication device, using the first wireless connection according to the Wi-Fi standard, by performing communication above the network layer of the OSI (Open Systems Interconnection) reference model, a transmission request transmission unit that transmits a public key transmission request to the communication device; When the transmission request is transmitted to the communication device, a public key receiving unit that receives the public key from the communication device by performing communication above the network layer using the first wireless connection; A migration request transmission unit that transmits a migration request to the communication device using the first wireless connection, wherein the migration request is a request for migrating the state of the communication device from a non-response state to a response state, the non-response state is a state in which an authentication response cannot be transmitted to the terminal device, and the response state is a state in which the authentication response can be transmitted to the terminal device, the migration request transmission unit; A first communication control unit that executes a first control process for performing wireless communication according to a predetermined method between the terminal device and the communication device after the public key is received from the communication device, The wireless communication according to the predetermined method is an authentication request transmission process for transmitting an authentication request using the public key to the communication device, an authentication response reception process for receiving the authentication response from the communication device when the authentication request is transmitted to the communication device after the state of the communication device has shifted to the response state and the public key has been received from the communication device, a first connection information transmission process for transmitting first connection information to the communication device after the authentication response has been received from the communication device, where the first connection information is information used by the communication device to establish a second wireless connection conforming to the Wi-Fi standard between the communication device and an external device different from the terminal device, the first connection information transmission process, the first communication control unit including a computer program that functions as

12. A computer program for a terminal device, wherein the computer program causes the computer of the terminal device to perform the following parts, namely, a transmission request transmission unit that transmits a public key transmission request to the communication device by performing communication above the network layer of the OSI (Open Systems Interconnection) reference model using the first wireless connection established between the terminal device and the communication device and conforming to the Wi-Fi standard, a public key reception unit that receives the public key from the communication device by performing communication above the network layer using the first wireless connection when the transmission request is transmitted to the communication device, a channel information reception unit that receives channel information indicating one or more channels available to the communication device from the communication device using the first wireless connection, a first communication control unit that executes a first control process for performing wireless communication according to a predetermined method between the terminal device and the communication device after the public key and the channel information have been received from the communication device, wherein the wireless communication according to the predetermined method is an authentication request transmission process for transmitting an authentication request using the public key to the communication device using one of the one or more wireless channels indicated by the channel information, an authentication response reception process for receiving an authentication response from the communication device when the authentication request is transmitted to the communication device, A first connection information transmission process that transmits first connection information to the communication device after receiving the authentication response from the communication device, where the first connection information is information used by the communication device to establish a second wireless connection conforming to the Wi-Fi standard between the communication device and an external device different from the terminal device, the first connection information transmission process, including the first communication control unit, A computer program that functions as.

13. A computer program for a terminal device, The computer program causes the computer of the terminal device to perform the following parts, namely, A first wireless connection established between the terminal device and the communication device, an authentication information transmission unit that transmits user authentication information to the communication device using the first wireless connection conforming to the Wi-Fi standard, A transmission request transmission unit that transmits a public key transmission request to the communication device by performing communication above the network layer of the OSI (Open Systems Interconnection) reference model using the first wireless connection, A public key reception unit that receives the public key from the communication device by performing communication above the network layer using the first wireless connection when the transmission request is transmitted to the communication device, A first communication control unit that executes a first control process for performing wireless communication according to a predetermined method between the terminal device and the communication device after receiving the public key from the communication device, The wireless communication according to the predetermined method is An authentication request transmission process that transmits an authentication request using the public key to the communication device, An authentication response reception process that receives an authentication response from the communication device when the authentication request is transmitted to the communication device, A first connection information transmission process that transmits first connection information to the communication device after receiving the authentication response from the communication device, where the first connection information is information used by the communication device to establish a second wireless connection conforming to the Wi-Fi standard between the communication device and an external device different from the terminal device, the first connection information transmission process, including the first communication control unit, Function as, In the communication device, when the authentication of the user authentication information is successful and the first connection information is received from the terminal device, the second wireless connection is established between the communication device and the external device. A computer program in which, in the communication device, when the authentication of the user authentication information fails, the second wireless connection is not established.

14. The computer program according to any one of claims 11 to 13, wherein the public key is information obtained using the identification information of the communication device.

15. The computer program further causes the computer to function as a device information receiving unit that receives device information related to the communication device from the communication device using the first wireless connection, and a display control unit that causes the received device information to be displayed on the display unit of the terminal device. The computer program according to any one of claims 11 to 14.

16. The computer program further causes the computer to function as an availability information receiving unit that receives availability information indicating whether or not the communication device supports the predetermined method from the communication device using the first wireless connection, wherein the transmission request transmission unit transmits the transmission request to the communication device when the availability information indicates that the communication device supports the predetermined method, The computer program further causes the computer to function as a second communication control unit that executes a second control process for performing wireless communication according to a method different from the predetermined method of the Wi-Fi standard between the terminal device and the communication device when the availability information indicates that the communication device does not support the predetermined method, wherein the wireless communication according to the different method is a second connection information transmission process for transmitting third connection information to the communication device using the first wireless connection without transmitting the transmission request to the communication device, and the third connection information is information used by the communication device to establish a third wireless connection according to the Wi-Fi standard between the communication device and the external device. The second connection information transmission process. The computer program according to any one of claims 11 to 15, which functions as the second communication control unit including the above.

17. The predetermined method is a DPP (abbreviation for Device Provisioning Protocol) method, The first connection information is a Configuration Object of the DPP method, the computer program according to any one of claims 11 to 16.

18. A terminal device, A first establishment unit that establishes a first wireless connection compliant with the Wi-Fi standard with a communication device, A transmission request transmission unit that transmits a public key transmission request to the communication device by performing communication above the network layer of the OSI (abbreviation for Open Systems Interconnection) reference model using the first wireless connection, A public key reception unit that receives the public key from the communication device by performing communication above the network layer using the first wireless connection when the transmission request is transmitted to the communication device, A transition request transmission unit that transmits a transition request to the communication device using the first wireless connection, where the transition request is a request for transitioning the state of the communication device from a non-response state to a response state, the non-response state is a state in which an authentication response cannot be transmitted to the terminal device, and the response state is a state in which the authentication response can be transmitted to the terminal device, the transition request transmission unit, An authentication request transmission unit that transmits an authentication request using the public key after the public key is received from the communication device, where the authentication request complies with a predetermined method of the Wi-Fi standard to the communication device, An authentication response reception unit that receives the authentication response compliant with the predetermined method from the communication device when the authentication request is transmitted to the communication device after the state of the communication device is transitioned to the response state and the public key is received from the communication device, A first connection information transmission unit that transmits first connection information compliant with the predetermined method to the communication device after the authentication response is received from the communication device, where the first connection information is information used by the communication device to establish a second wireless connection compliant with the Wi-Fi standard between the communication device and an external device different from the terminal device, the first connection information transmission unit, A terminal device comprising the above.

19. A terminal device, A first establishment unit that establishes a first wireless connection compliant with the Wi-Fi standard with a communication device, A transmission request transmitter that transmits a public key transmission request to the communication device by performing communication above the network layer of the OSI (Open Systems Interconnection) reference model using the first wireless connection. A public key receiver that receives the public key from the communication device by performing communication above the network layer using the first wireless connection when the transmission request is transmitted to the communication device. A channel information receiver that receives, from the communication device, channel information indicating one or more channels available to the communication device using the first wireless connection. An authentication request transmitter that transmits, to the communication device, an authentication request using the public key, which is an authentication request in which the public key is used, according to a predetermined method of the Wi-Fi standard, using one of the one or more wireless channels indicated by the channel information after the public key and the channel information are received from the communication device. An authentication response receiver that receives, from the communication device, an authentication response according to the predetermined method when the authentication request is transmitted to the communication device. A first connection information transmitter that transmits, to the communication device, first connection information according to the predetermined method after the authentication response is received from the communication device, where the first connection information is information used by the communication device to establish a second wireless connection according to the Wi-Fi standard between the communication device and an external device different from the terminal device. A terminal device comprising the above.

20. A terminal device, A first establishment unit that establishes a first wireless connection according to the Wi-Fi standard with a communication device, and An authentication information transmitter that transmits user authentication information to the communication device using the first wireless connection, A transmission request transmitter that transmits a public key transmission request to the communication device by performing communication above the network layer of the OSI (Open Systems Interconnection) reference model using the first wireless connection, A public key receiver that receives the public key from the communication device by performing communication above the network layer using the first wireless connection when the transmission request is transmitted to the communication device. An authentication request transmission unit that, after receiving the public key from the communication device, transmits to the communication device an authentication request that uses the public key and conforms to a predetermined method of the Wi-Fi standard. An authentication response reception unit that, when the authentication request is transmitted to the communication device, receives from the communication device an authentication response conforming to the predetermined method. A first connection information transmission unit that, after receiving the authentication response from the communication device, transmits to the communication device first connection information conforming to the predetermined method, where the first connection information is information used by the communication device to establish a second wireless connection conforming to the Wi-Fi standard between the communication device and an external device different from the terminal device. Comprising: In the communication device, when authentication of the user authentication information is successful and the first connection information is received from the terminal device, the second wireless connection is established between the communication device and the external device. In the communication device, when authentication of the user authentication information fails, the second wireless connection is not established. Terminal device.

Citation Information

Patent Citations

  • Communication device, control method, and program

    JP2019193120A

  • Communication device, communication method, and program

    JP2020043473A

  • Communication device, control method, and program

    JP2020088620A

  • Terminal apparatus and computer program for terminal apparatus

    JP2020113851A