Bug report #15360

WFS don't conserve username and password

Added by Pascal Obstétar over 7 years ago. Updated over 7 years ago.

Status:Closed
Priority:Severe/Regression
Assignee:Alessandro Pasotti
Category:Web Services clients/WFS
Affected QGIS version:master Regression?:No
Operating System: Easy fix?:No
Pull Request or Patch supplied:No Resolution:
Crashes QGIS or corrupts data:No Copied to github as #:23292

Description

When you use wfs connection and would store id and password, qgis conserve just id but not the password and the connection could not be ?

Associated revisions

Revision f49bd5ca
Added by Alessandro Pasotti over 7 years ago

[WFS] Fixes #15360 and other issues

- fixes authcfg params not passed to requests
- fixes backward URI compatibility
- fixes version parameter ignored in old style URI
- check for "user" in addition to "username" in WFS URI

Revision 43274b11
Added by Alessandro Pasotti over 7 years ago

Merge pull request #3368 from elpaso/wfs_fixes

Try to fix #15360

Revision 5e71dfa4
Added by Alessandro Pasotti over 7 years ago

[WFS] Fixes #15360 and other issues

- fixes authcfg params not passed to requests
- fixes backward URI compatibility
- fixes version parameter ignored in old style URI
- check for "user" in addition to "username" in WFS URI

(cherry-picked from f49bd5ca449e332aa547f9dac31b391e438d2b31)

Revision 56400b14
Added by Alessandro Pasotti over 7 years ago

[WFS] Fixes #15360 and other issues

- fixes authcfg params not passed to requests
- fixes backward URI compatibility
- fixes version parameter ignored in old style URI
- check for "user" in addition to "username" in WFS URI

(cherry-picked from f49bd5ca449e332aa547f9dac31b391e438d2b31)

Revision c80e5d13
Added by Alessandro Pasotti over 7 years ago

[bugfix] Fixes WFS HTTP auth basic username/password

Fixes #15360 and #15597

Revision 5daaf942
Added by Alessandro Pasotti over 7 years ago

[bugfix] Fixes WFS HTTP auth basic username/password

Fixes #15360 and #15597

History

#1 Updated by Giovanni Manghi over 7 years ago

  • Subject changed from WFS don't conserve id and password to WFS don't conserve username and password

So this seems to be #6609 all over again.

#2 Updated by Alessandro Pasotti over 7 years ago

Confirmed with master_2 and 2.16.

This is a severe regression and breaks most of our PKI authentication tests for WFS provider.

The problem might originate from https://github.com/qgis/QGIS/blob/master_2/src/providers/wfs/qgswfsdatasourceuri.cpp#L48 that discards all auth information to store them in a QgsWFSAuthorization class.

When the requestCapabilities request is done in https://github.com/qgis/QGIS/blob/master_2/src/providers/wfs/qgswfsrequest.cpp#L104 the auth fields are blank and no authorization is sent.

All getCapabilities.requestCapabilities should also be checked, for example:
QgsWFSConnectionItem::createChildren()

In general, all calls to QgsWFSDataSourceURI::uri() are probably broken as far as authentication is concerned.

#3 Updated by Alessandro Pasotti over 7 years ago

  • Assignee set to Alessandro Pasotti

#4 Updated by Anonymous over 7 years ago

  • Status changed from Open to Closed

#5 Updated by Giovanni Manghi over 7 years ago

  • Target version changed from Version 2.16 to Version 2.18
  • Affected QGIS version changed from 2.16.0 to master_2
  • Operating System deleted (linux ubuntu)
  • Status changed from Closed to Reopened

Still true for username (not password), also on master.

#6 Updated by Giovanni Manghi over 7 years ago

  • OS version deleted (16.04)
  • Affected QGIS version changed from master_2 to master

Still true on master.

#7 Updated by Anonymous over 7 years ago

  • Status changed from Reopened to Closed

Also available in: Atom PDF