Skip to content

[Bug]: Unable to add open network - asks for WPA passphrase #2008

Description

@meandthemachine

Code of Conduct

  • I agree to follow this project's Code of Conduct.

Issue reporting checklist

Operating System

Raspberry Pi OS Desktop 64-bit Debian 12 (bookworm)

Installation method

Quick install

Onboard wireless chipset or external adapter?

External adapter

Hardware

Raspberry Pi 4 Model B

RaspAP version

Latest

Other software or services running with RaspAP?

No other software

Contact details (optional)

No response

Bug description

The code that parses the network properties and serves the content of the WiFi client page sets the protocol property's value to 'OPEN' in all-capital letters:

However, the code that consumes and handles the actions of the WiFi client page compares to 'Open' in

if ($network['protocol'] === 'Open') {

This fails and leads to the behaviour described in the title.

I think a constant should be introduced to get both parts in sync.
Uppercase presentation for UI purpose should/could be done in the template.

Steps to reproduce

Try to add an open network.
Will ask for WPA passphrase.

Screenshots

No response

Additional context

No response

Relevant log output

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions