[Geoserver-users] Setting up authKey module with external key provider

Hello all,

I am trying to get the this working, but I believe I am missing something.

GEOSERVER_VERSION=2.21.1

What I did:

  1. I installed the authkey extension (I can see it under server status then modules)
  2. I have setup the auth filter. (didn’t click synchronize)
    image.png
  3. Added that to the default key chain.
  4. I have a server returning just a default json {“name”: “admin”}
  5. I have set up a wms layer which I can get from a website using openlayer.

I am not sure what else to do to make this work. I don’t see geoserver doing that authkey filter and not communicating with the key provider server.

Thanks in advance,
Alin

···

Alin State | Software Engineer
+44 (0)7718 612525
alin.state@anonymised.com
Learn more at https://www.udlive.ioCheck us out on LinkedIn

Did you add the new authentication filter to the filter chains? If not, try to add it to the default one at least.

image.png

···

Regards,

Alessio Fabiani

==
GeoServer Professional Services from the experts!

Visit http://bit.ly/gs-services-us for more information.

Ing. Alessio Fabiani

@alfa7691
Founder/Technical Lead

GeoSolutions Group
phone: +39 0584 962313

fax: +39 0584 1660272

mob: +39 331 6233686

https://www.geosolutionsgroup.com/

http://twitter.com/geosolutions_it


Con riferimento alla normativa sul trattamento dei dati personali (Reg. UE 2016/679 - Regolamento generale sulla protezione dei dati “GDPR”), si precisa che ogni circostanza inerente alla presente email (il suo contenuto, gli eventuali allegati, etc.) è un dato la cui conoscenza è riservata al/i solo/i destinatario/i indicati dallo scrivente. Se il messaggio Le è giunto per errore, è tenuta/o a cancellarlo, ogni altra operazione è illecita. Le sarei comunque grato se potesse darmene notizia.

This email is intended only for the person or entity to which it is addressed and may contain information that is privileged, confidential or otherwise protected from disclosure. We remind that - as provided by European Regulation 2016/679 “GDPR” - copying, dissemination or use of this e-mail or the information herein by anyone other than the intended recipient is prohibited. If you have received this email by mistake, please notify us immediately by telephone or e-mail.

Hi Alin

I have 4 suggestions to assist you:

Does it work using a properties file instead of the web service? See https://docs.geoserver.org/latest/en/user/extensions/authkey/index.html#key-provider-using-a-property-file

Try setting GeoServer logging level to verbose to see the AuthKey log output.

Your regex is looking for a response like {“user”: “admin”} (not “name”) - but you’re not hitting this problem yet

In the (default) Filter Chain, under Selected, try reordering the list so that AuthKey is above Basic and Anonymous

hth

Peter

On Wed, 05 Apr 2023, 17:18 Alin State, <alin.state@…11725…> wrote:

Hello all,

I am trying to get the this working, but I believe I am missing something.

GEOSERVER_VERSION=2.21.1

What I did:

  1. I installed the authkey extension (I can see it under server status then modules)
  2. I have setup the auth filter. (didn’t click synchronize)
    image.png
  3. Added that to the default key chain.
  4. I have a server returning just a default json {“name”: “admin”}
  5. I have set up a wms layer which I can get from a website using openlayer.

I am not sure what else to do to make this work. I don’t see geoserver doing that authkey filter and not communicating with the key provider server.

Thanks in advance,
Alin

Alin State | Software Engineer
+44 (0)7718 612525
alin.state@anonymised.com
Learn more at https://www.udlive.ioCheck us out on LinkedIn

Disclaimer:

The content of this email is confidential and intended for the recipient specified in message only. It is strictly forbidden to share any part of this message with any third party, without a written consent of the sender. If you received this message by mistake, please reply to this message and follow with its deletion, so that we can ensure such a mistake does not occur in the future.
The security of customers and suppliers as a priority. Therefore, we have put efforts into ensuring that the message is error and virus-free. Unfortunately, full security of the email cannot be ensured as, despite our efforts, the data included in emails could be infected, intercepted, or corrupted. Therefore, the recipient should check the email for threats with proper software, as the sender does not accept liability for any damage inflicted by viewing the content of this email.
No employee has the authority to conclude any binding contract without an explicit written consent of their supervisor. Therefore, any will to enter into an agreement must be confirmed by a second manager or director.
Any quotation contained is sent to compare available offers and does not imply entering into a legally binding contract.
Please do not print this email unless it is necessary. Every unprinted email helps the environment.
The views and opinions included in this email belong to their author and do not necessarily mirror the views and opinions of the company. Our employees are obliged not to make any defamatory clauses, infringe, or authorise infringement of any legal right. Therefore, the company will not take any liability for such statements included in emails. In case of any damages or other liabilities arising, employees are fully responsible for the content of their emails.


Geoserver-users mailing list

Please make sure you read the following two resources before posting to this list:

If you want to request a feature or an improvement, also see this: https://github.com/geoserver/geoserver/wiki/Successfully-requesting-and-integrating-new-features-and-improvements-in-GeoServer

Geoserver-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-users

image.png