Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Wi-Fi connection gets stuck on a specific Wi-Fi network (IDFGH-13889) #14730

Open
3 tasks done
matoha opened this issue Oct 15, 2024 · 5 comments
Open
3 tasks done

Wi-Fi connection gets stuck on a specific Wi-Fi network (IDFGH-13889) #14730

matoha opened this issue Oct 15, 2024 · 5 comments
Assignees
Labels
Resolution: NA Issue resolution is unavailable Status: Done Issue is done internally Type: Bug bugs in IDF

Comments

@matoha
Copy link

matoha commented Oct 15, 2024

Answers checklist.

  • I have read the documentation ESP-IDF Programming Guide and the issue is not addressed there.
  • I have updated my IDF branch (master or release) to the latest version and checked that the issue is present there.
  • I have searched the issue tracker for a similar issue and not found a similar issue.

IDF version.

v4.4.2

Espressif SoC revision.

ESP32-S3 (QFN56) (revision v0.1)

Operating System used.

macOS

How did you build your project?

Command line with idf.py

If you are using Windows, please specify command line type.

None

Development Kit.

Custom board, incl. ESP32-S3-WROOM-1U

Power Supply used.

USB

What is the expected behavior?

Hi,

We have been successfully using the ESP32-S3 for a range of our products. However, at a specific customer network, we're unable to get the devices to connect and as it is a building-wide Wi-Fi, we're unable to change the Wi-Fi settings. The device connection gets stuck in a connecting mode and no connection happens. I've attached logs below for a successful vs unsuccessful connection, both taken using the same device.

The only difference I can see is that the network that works report wifi:connect_op: status=0, auth=5, cipher=3 whereas the one that doesn't work shows wifi:connect_op: status=0, auth=5, cipher=12 . However, I'm unable to find what cipher=12 stands for as the driver is closed-source. The network with issues is b/g/n WPA2-PSK with CCMP/GCMP/CCMP256/GCMP256 support.

I would be grateful if you could point me to any issues the logs might be indicating?

Thanks
Martin

What is the actual behavior?

The device never connects to Wi-Fi.

Steps to reproduce.

The source code is based on the https://github.com/espressif/esp-idf/tree/release/v4.4/examples/wifi/getting_started/station , with some modifications. I'm unable to provide a way to remotely reproduce this as this is restricted to a very specific Wi-Fi network.

Debug Logs.

[Wi-Fi connection is attempted to a network that doesn't work]
[Wi-Fi starts]

I (2666) wifi:wifi driver task: 3fcb07dc, prio:23, stack:6656, core=0
I (2711) wifi:wifi firmware version: eeaa27d
I (2724) wifi:wifi certification version: v7.0
I (2737) wifi:config NVS flash: enabled
I (2752) wifi:config nano formating: disabled
I (2765) wifi:Init data frame dynamic rx buffer num: 32
I (2778) wifi:Init management frame dynamic rx buffer num: 32�
I (2801) wifi:Init static tx buffer num: 16
I (2814) wifi:Init tx cache buffer num: 32
I (2828) wifi:Init static tx FG buffer num: 2
I (2842) wifi:Init static rx buffer size: 1600
I (2855) wifi:Init static rx buffer num: 10
I (2868) wifi:Init dynamic rx buffer num: 32
W (09:21:16.156) MatohaIntConn: Connecting to WiFi SSID *redacted*
D (2895) wifi:clear blacklist
D (2963) wifi:filter: set rx policy=0
I (2976) wifi:mode : sta (48:27:e2:f0:18:7c)
I (2990) wifi:enable tsf
D (3002) wifi:filter: set rx policy=1
D (3016) wifi:connect status 0 -> 0
D (3031) wifi:Start wifi connect
D (3044) wifi:connect status 0 -> 0
D (3057) wifi:connect chan=0
D (3069) wifi:first chan=1
D (3082) wifi:connect status 0 -> 1
D (3094) wifi:filter: set rx policy=3
D (3108) wifi:clear scan ap list
D (3121) wifi:start scan: type=0x50f, priority=2, cb=0x420af6e4, arg=0x0, ss_state=0x1, time=2363069, index=0
D (3134) wifi:perform scan: ss_state=0x9, chan<1,0>, dur<0,120>
D (3152) wifi:rsn valid: gcipher=3 ucipher=12 akm=5
D (3168) wifi:rsn valid: gcipher=3 ucipher=12 akm=5
D (3182) wifi:rsn valid: gcipher=3 ucipher=12 akm=5
D (3196) wifi:rsn valid: gcipher=3 ucipher=12 akm=5
D (3214) wifi:rsn valid: gcipher=3 ucipher=12 akm=5
D (3271) wifi:scan end: arg=0x0, status=0, ss_state=0x3
D (3285) wifi:perform scan: ss_state=0x9, chan<2,0>, dur<0,120>
D (3540) wifi:scan end: arg=0x0, status=0, ss_state=0x3
D (3553) wifi:perform scan: ss_state=0x9, chan<3,0>, dur<0,120>
D (3807) wifi:scan end: arg=0x0, status=0, ss_state=0x3
D (3822) wifi:perform scan: ss_state=0x9, chan<4,0>, dur<0,120>
D (4077) wifi:scan end: arg=0x0, status=0, ss_state=0x3
D (4090) wifi:perform scan: ss_state=0x9, chan<5,0>, dur<0,120>
D (4344) wifi:scan end: arg=0x0, status=0, ss_state=0x3
D (4359) wifi:perform scan: ss_state=0x9, chan<6,0>, dur<0,120>
D (4382) wifi:rsn valid: gcipher=3 ucipher=12 akm=5
D (4396) wifi:profile match: ss_state=0x7
D (4541) wifi:rsn valid: gcipher=3 ucipher=12 akm=5
D (4555) wifi:set max rate: from <rate=130, phy=3, sig=0> to <rate=144, phy=3 sig=0>
D (4570) wifi:sig_b=0, sig_g=0, sig_n=0, max_b=22, max_g=108, max_n=144
D (4582) wifi:profile match: ss_state=0x7
D (4596) wifi:rsn valid: gcipher=3 ucipher=12 akm=5
D (4614) wifi:scan end: arg=0x0, status=0, ss_state=0x7
D (4628) wifi:perform scan: ss_state=0xd, chan<7,0>, dur<0,120>
D (4887) wifi:scan end: arg=0x0, status=0, ss_state=0x7
D (4900) wifi:perform scan: ss_state=0xd, chan<8,0>, dur<0,120>
D (5154) wifi:scan end: arg=0x0, status=0, ss_state=0x7
D (5169) wifi:perform scan: ss_state=0xd, chan<9,0>, dur<0,120>
D (5424) wifi:scan end: arg=0x0, status=0, ss_state=0x7
D (5437) wifi:perform scan: ss_state=0xd, chan<10,0>, dur<0,120>
D (5691) wifi:scan end: arg=0x0, status=0, ss_state=0x7
D (5706) wifi:perform scan: ss_state=0xd, chan<11,0>, dur<0,120>
D (5961) wifi:scan end: arg=0x0, status=0, ss_state=0x7
D (5976) wifi:perform scan: ss_state=0xd, chan<12,0>, dur<360,360>
D (6229) wifi:scan end: arg=0x0, status=0, ss_state=0x7
D (6244) wifi:perform scan: ss_state=0xd, chan<13,0>, dur<360,360>
D (6499) wifi:scan end: arg=0x0, status=0, ss_state=0x7
D (6512) wifi:perform scan: ss_state=0xd, chan<14,0>, dur<360,360>
D (6766) wifi:scan end: arg=0x0, status=0, ss_state=0x7
D (6780) wifi:filter: set rx policy=4
D (6794) wifi:first chan=1
D (6806) wifi:handoff_cb: status=0
D (6819) wifi:ap found, mac=48:a9:8a:ba:2f:6b
D (6831) wifi:new_bss=0x3fca5ae8, cur_bss=0x0, new_chan=<6,1>, cur_chan=1
D (6845) wifi:filter: set rx policy=5
I (6859) wifi:new:<6,1>, old:<1,0>, ap:<255,255>, sta:<6,1>, prof:1
D (6872) wifi:connect_op: status=0, auth=5, cipher=12 
D (6886) wifi:clear scan ap list

[no further connection effort happens, no connection is established]


[Wi-Fi connection is attempted to a network that works]
[Wi-Fi starts]

I (2672) wifi:wifi driver task: 3fcb07f4, prio:23, stack:6656, core=0
I (2716) wifi:wifi firmware version: eeaa27d
I (2730) wifi:wifi certification version: v7.0
I (2758) wifi:Init management frame dynamic rx buffer num: 32
I (2772) wifi:Init management short buffer num: 32
I (2785) wifi:Init static tx buffer num: 16
I (2811) wifi:Init static rx buffer size: 1600
I (2824) wifi:Init static rx buffer num: 10
I (2837) wifi:Init dynamic rx buffer num: 32
W (09:23:28.117) MatohaIntConn: Connecting to WiFi SSID MatohaNet�
D (2863) wifi:clear blacklist
D (2995) wifi:filter: set rx policy=0
I (3009) wifi:mode : sta (48:27:e2:f0:18:7c)
I (3023) wifi:enable tsf
D (3035) wifi:filter: set rx policy=1
D (3048) wifi:connect status 0 -> 0
D (3063) wifi:Start wifi connect
D (3077) wifi:connect status 0 -> 0
D (3091) wifi:connect chan=0
D (3103) wifi:first chan=11
D (3116) wifi:connect status 0 -> 1
D (3128) wifi:filter: set rx policy=3
D (3142) wifi:clear scan ap list
D (3155) wifi:start scan: type=0x50f, priority=2, cb=0x420af6e4, arg=0x0, ss_state=0x1, time=2394126, index=0
D (3169) wifi:perform scan: ss_state=0x9, chan<11,0>, dur<0,120>
D (3191) wifi:rsn valid: gcipher=3 ucipher=3 akm=5
D (3206) wifi:profile match: ss_state=0x7
D (3255) wifi:rsn valid: gcipher=3 ucipher=3 akm=5
D (3270) wifi:set max rate: from <rate=130, phy=3, sig=0> to <rate=144, phy=3 sig=0>
D (3284) wifi:sig_b=0, sig_g=0, sig_n=0, max_b=22, max_g=108, max_n=144
D (3297) wifi:profile match: ss_state=0x7
D (3310) wifi:scan end: arg=0x0, status=0, ss_state=0x7
D (3326) wifi:perform scan: ss_state=0xd, chan<1,0>, dur<0,120>
D (3579) wifi:scan end: arg=0x0, status=0, ss_state=0x7
D (3593) wifi:perform scan: ss_state=0xd, chan<2,0>, dur<0,120>
D (3848) wifi:scan end: arg=0x0, status=0, ss_state=0x7
D (3863) wifi:perform scan: ss_state=0xd, chan<3,0>, dur<0,120>
D (4118) wifi:scan end: arg=0x0, status=0, ss_state=0x7
D (4131) wifi:perform scan: ss_state=0xd, chan<4,0>, dur<0,120>
D (4386) wifi:scan end: arg=0x0, status=0, ss_state=0x7
D (4400) wifi:perform scan: ss_state=0xd, chan<5,0>, dur<0,120>
D (4655) wifi:scan end: arg=0x0, status=0, ss_state=0x7
D (4669) wifi:perform scan: ss_state=0xd, chan<6,0>, dur<0,120>
D (4924) wifi:scan end: arg=0x0, status=0, ss_state=0x7
D (4938) wifi:perform scan: ss_state=0xd, chan<7,0>, dur<0,120>
D (5193) wifi:scan end: arg=0x0, status=0, ss_state=0x7
D (5207) wifi:perform scan: ss_state=0xd, chan<8,0>, dur<0,120>
D (5461) wifi:scan end: arg=0x0, status=0, ss_state=0x7
D (5476) wifi:perform scan: ss_state=0xd, chan<9,0>, dur<0,120>
D (5731) wifi:scan end: arg=0x0, status=0, ss_state=0x7
D (5745) wifi:perform scan: ss_state=0xd, chan<10,0>, dur<0,120>
D (5999) wifi:scan end: arg=0x0, status=0, ss_state=0x7
D (6013) wifi:perform scan: ss_state=0xd, chan<12,0>, dur<360,360>
D (6268) wifi:scan end: arg=0x0, status=0, ss_state=0x7
D (6282) wifi:perform scan: ss_state=0xd, chan<13,0>, dur<360,360>
D (6537) wifi:scan end: arg=0x0, status=0, ss_state=0x7
D (6550) wifi:perform scan: ss_state=0xd, chan<14,0>, dur<360,360>
D (6806) wifi:scan end: arg=0x0, status=0, ss_state=0x7
D (6820) wifi:filter: set rx policy=4
D (6833) wifi:first chan=1
D (6845) wifi:handoff_cb: status=0
D (6859) wifi:ap found, mac=04:95:e6:e4:5f:50
D (6872) wifi:new_bss=0x3fca5ae8, cur_bss=0x0, new_chan=<11,0>, cur_chan=1
D (6886) wifi:filter: set rx policy=5
I (6900) wifi:new:<11,0>, old:<1,0>, ap:<255,255>, sta:<11,0>, prof:1
D (6913) wifi:connect_op: status=0, auth=5, cipher=3 
D (6926) wifi:auth mode is not none
D (6940) wifi:connect_bss: auth=1, reconnect=0
I (6953) wifi:state: init -> auth (b0)
D (6967) wifi:start 1s AUTH timer
D (6980) wifi:clear scan ap list
D (6995) wifi:recv auth: seq=2, status=0
I (7008) wifi:state: auth -> assoc (0)
D (7023) wifi:restart connect 1s timer for assoc
D (7056) wifi:recv assoc: type=0x10
D (7070) wifi:filter: set rx policy=6
I (7084) wifi:state: assoc -> run (10)
D (7097) wifi:start 10s connect timer for 4 way handshake
I (7123) wifi:connected with MatohaNet, aid = 3, channel 11, BW20, bssid = 04:95:e6:e4:5f:50
I (7138) wifi:security: WPA2-PSK, phy: bgn, rssi: -72
D (7152) wifi:remove all except 04:95:e6:e4:5f:50 from rc list
D (7164) wifi:clear blacklist
D (7188) wifi:filter: set rx policy=7
I (7202) wifi:pm start, type: 1
I (7216) wifi:set rx beacon pti, rx_bcn_pti: 14, bcn_timeout: 14, mt_pti: 25000, mt_time: 10000
D (7229) wifi:Send sta connected event
D (7242) wifi:connect status 1 -> 5
D (7254) wifi:obss scan is disabled
D (7268) wifi:start obss scan: obss scan is stopped
I (7282) wifi:BcnInt:102400, DTIM:1

[Wi-Fi works here as expected]

More Information.

No response

@matoha matoha added the Type: Bug bugs in IDF label Oct 15, 2024
@Alvin1Zhang
Copy link
Collaborator

Thanks for reporting.

@espressif-bot espressif-bot added the Status: Opened Issue is new label Oct 16, 2024
@github-actions github-actions bot changed the title Wi-Fi connection gets stuck on a specific Wi-Fi network Wi-Fi connection gets stuck on a specific Wi-Fi network (IDFGH-13889) Oct 16, 2024
@nishanth-radja
Copy link
Collaborator

@matoha have you enabled the suiteB support with 192bit key in the component config->supplicant in the menuconfig ?

@hansw123
Copy link
Collaborator

@matoha
auth 5 means wpa2_psk
cipher=12 means AES_256_GCM which looks not support in your wifi network
chiper = 3 means AES_CCM

@espressif-bot espressif-bot added Status: In Progress Work is in progress and removed Status: Opened Issue is new labels Oct 18, 2024
@matoha
Copy link
Author

matoha commented Oct 18, 2024

Hi @hansw123 ,

Thanks for the reply. Is there a way to disable cipher=12 on the ESP side, and force cipher=3, since it doesn't seem to be working? I've reviewed the documentation but can't find anything.

Thanks
Martin

@hansw123
Copy link
Collaborator

@matoha
sorry ,I made a mistake ,this log means ap need sta support AES_256_GCM,but station don\t support
just open ESP_WIFI_GCMP_SUPPORT in menuconfig can be ok

@espressif-bot espressif-bot added Status: Reviewing Issue is being reviewed and removed Status: In Progress Work is in progress labels Oct 22, 2024
@espressif-bot espressif-bot added Status: Done Issue is done internally Resolution: NA Issue resolution is unavailable and removed Status: Reviewing Issue is being reviewed labels Jan 10, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Resolution: NA Issue resolution is unavailable Status: Done Issue is done internally Type: Bug bugs in IDF
Projects
None yet
Development

No branches or pull requests

5 participants