This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

LAUNCHCC3220MODASF: Can not connect to a wifi network due to password containing non alpha characters

Part Number: LAUNCHCC3220MODASF

Hello there,

I have an issue connecting to a wifi network with a password such as "walou5%." (double quotes note included).

I made the following tests with the provisioning application from the sdk and a TP-Link TL-WR802N setup as wifi access point :

- setup wifi password to "walou5%." -> CC3220 can not connect to the network

- setup wifi password to "babayaga" -> CC3220 connects to the network

Here is the log of the provisioning app, using the TI smartphone app on iOS (same issue when making setup using http pages) :

[Provisioning] Profile Added: SSID: No Wi-Fi No Cry
[Provisioning] Profile confirmation failed: Connection failed (<-- walou5%.)
[Provisioning] Profile Added: SSID: No Wi-Fi No Cry
[Provisioning] Profile confirmation: WLAN Connected! (<-- babayaga)
[Provisioning] Profile confirmation: IP Acquired!

I decided trying to test this as connecting to an iPhone in tethering mode failed the same when the password contains non alphanum characters. I had the same issue with 3 other access points : TP link, Linksys and Freebox (french DSL provider). I can try to get the accurate models but I do not feel like it is of importance for this matter.

Thank you very much for helping.

Best regards,

Maximilien.

  • Hi Maximilien,

    Liking the password choices. I'll have to try this on the provisioning app, but passwords with non-alphabetical characters work OK when attempting a direct connection (I.E. wlanconnect within code).

    I wouldn't imagine it's an issue with your APs. Can you explain your "tethering mode" setup? Did you just have your Iphone acting as a hotspot with a non-alpha wifi password?

    Best,
    Kevin
  • Hi Kevin,

    I am glad the names are of your taste.

    About the tethering mode : yes I used an iPhone as a hotspot and changed the password with and without non-alpha characters, the same as with the TP-link wireless device I made tests with.

    I will be very happy to read from you when you have made the tests on your side.

    I can not use direct connection API in my project.

    Best regards,

    Maximilien.

  • Hi Maximilien,

    Sorry it took me a while to get to this. I've messed around with the provisioning IOS App with a non-alpha password ==> "thewalou5%"

    I was unsuccessful in getting AP provisioning to work on the App, resulting in a failed connection. The terminal showed the following:

     Starting Provisioning! mode=2 (0-AP, 1-SC, 2-AP+SC, 3-AP+SC+WAC)
    
     [Provisioning] Profile Added: SSID: mySSID
     [Provisioning] Profile Added: SSID: mySSID
     [Provisioning] Profile confirmation failed: Connection failed

    However, enabling Smart Config on the App lead to the provisioning being successful. The terminal showed the following:

    Can you try using Smart Config and using that for the time being? I'm not sure why AP mode is not working and will need to investigate this further.

    Let me know if you need any help with getting Smart Config to work.

    Hope this helps,

    Kevin

  • Hi Kevin,

    Unfortunately using Smart Config is not an option for my project. Only AP configuration is possible.

    Hope investigating will not be too long.

    Thanks a lot for your help.

    Best regards,

    Maximilien.

  • Hi Guys,

    After quick look that looks like a "classic C" bug in NWP http server code. Formating character % is not properly escaped in C code in NWP.

    For example if you add profile with SSID: "%s" profile with SSID "0ex.html" is added. As to be honest this bug can be serious security issue.

    Update: After some investigation, I think security risk of this bug is small. But it still need to be checked by TI side.

    Update2: I looked closely to web configuration and there is more problems:

    - device name have some issue as strings in profiles

    - IP addresses can be set to broadcast IP

    - can be set wrong subnet mask

    Jan

  • Hi,

    Still looking into this further. I checked if adding a profile directly and enabling auto connection policy had any issues, but that worked OK.

    Seems to be specifically related to AP provisioning whether through the App or a browser.

    Thanks,
    Kevin
  • Hi,

    It appears other non-alpha characters within passwords work, just not the % sign.

    Passwords such as "thewalou!" and "thewalou&" worked on my end without issues.

    Best,
    Kevin
  • Hi Kevin,

    As I said. Issue is in source code of http server in NWP. When you insert string with % into any string this string is not saved properly. This string from web likely goes into sprint() or printf() function inside NWP code and because character % is not escaped, it caused this problem.

    Jan
  • Hi,

    I performed provisioning setup with 12 devices using my code, derived for that part from the provioning sample code.
    I had CC3220 connection to the AP issues : it sometimes does not find the AP (although it was listed in the found SSIDs) or has passwords issues. The AP is 3 meters away and reliable, I remember I had the same issues from time to time with the TP-link AP.
    The thing is: making the same provisioning process right after the faulty one works fine. The password is kept in the browser auto-fill settings so this is not a typo issue.
    Is there some logging options of the NWP so I can provide data for finding out the problem or publish to get help ?

    Thank you.

    Best regards,

    Maximilien.
  • Hi Maximilien,

    For this new issue you should open new thread.

    How to get NWP log is described here processors.wiki.ti.com/.../CC3120_&_CC3220_Capture_NWP_Logs

    Jan