Thank you for your answer. > I'd prefer to have explicit callbacks from hostapd (maybe to a script) to preserve those changes. I see that hapd_wps_cred_cb is called to update hostapd config. We can try here (somehow, maybe script?) update UCI config file.
But what about this scenario: 1) Run hostAP from UCI 2) Use UCI to update settings (for example SSID) and commit changes- but don't restart hostAP using 'wifi' command 3) Change password using External Registrar After step 2 both config files (from /etc/config/wireless and /var/run/hostapd-phyX.conf) contain different SSID. So password synchronization after step 3 will be very hard (how to decide which file is up to date... etc.). BR, Pawel On 24 March 2014 14:17, Felix Fietkau <n...@openwrt.org> wrote: > On 2014-03-24 14:06, Pawel Kulakowski wrote: > > Hi, > > When hostAP is running in Open mode and STA connects to it using PBC or > > PIN (wps enabled), then wpa_passphrase has been generated and added to > > the conf file (/var/run/hostapd-phyX.conf). Next, if AP is rebooted > > using UCI ('wifi' command), configuration will be overwritten by > > settings from /etc/config/wireless. This is the cause of issue: STA > > can't reconnect to the AP (wpa_passphrase is no longer valid). > > Similar problem can be observed using External Registrar: User can > > change password/ssid etc. using ER. But if UCI is used to restart hostAP > > ('wifi' command), changes will not be saved (hostapd conf file > > overwritten by settings from /etc/config/wireless). > > UCI is not a daemon (but only script) so it's not possible to monitor > > changes made in hostapd conf file (and decide which option is valid: > > from /etc/config/wireless or /var/run/...). Any ideas how solve this > > problem? > I think simply monitoring the config file for changes is a bad idea. I'd > prefer to have explicit callbacks from hostapd (maybe to a script) to > preserve those changes. > We can patch hostapd to implement that if needed. > > - Felix > >
_______________________________________________ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel