I configured a qgis project as follows:
As you can see, QGIS Server is now serving two layers using WFS or WMS service. These two layers don't have the user/pass parameters saved in their layer configuration, so every time I open the project I am prompted to insert the user pass for the postgis connection (they are postgis layers):
Now we go to client (another computer) and I open a QGIS Client and I configure a new WFS connection introducing the user and password here (the user and password for the server to connect to postgis database):
I can see in the getcapabilities request made by QGIS Client (captured using fiddler proxy) that it is now adding authorization info in header:
If I try to connect to this new connection I get there is no layer in Getcapabilities.
I don't now if QGIS server is not binding the user/pass stored in HTTP's header to the QGIS project to connect the layers to postgis or what...
My goal is to be able to connect to QGIS Server using WMS/WFS services with different users and the server should connect to postgis with the user introduced in the client (this way I could in postgis know which user is connected, making changes, and control what each user can or can't do)
أكثر...

As you can see, QGIS Server is now serving two layers using WFS or WMS service. These two layers don't have the user/pass parameters saved in their layer configuration, so every time I open the project I am prompted to insert the user pass for the postgis connection (they are postgis layers):

Now we go to client (another computer) and I open a QGIS Client and I configure a new WFS connection introducing the user and password here (the user and password for the server to connect to postgis database):

I can see in the getcapabilities request made by QGIS Client (captured using fiddler proxy) that it is now adding authorization info in header:

If I try to connect to this new connection I get there is no layer in Getcapabilities.
I don't now if QGIS server is not binding the user/pass stored in HTTP's header to the QGIS project to connect the layers to postgis or what...
My goal is to be able to connect to QGIS Server using WMS/WFS services with different users and the server should connect to postgis with the user introduced in the client (this way I could in postgis know which user is connected, making changes, and control what each user can or can't do)
أكثر...