Just to update, this behavior is the same in CAS 7.2.4.

2025-06-27 11:52:03,261 DEBUG 
[org.apereo.cas.support.geo.maxmind.MaxmindDatabaseGeoLocationService] - <Geo 
location for [/x.x.x.x] is calculated as [GeoLocationResponse(addresses=[], 
latitude=0.0, longitude=0.0)]>

None of the Geolocation services work, all return zeroes.



________________________________
From: AJ <a...@mindcrash.com>
Sent: Wednesday, June 25, 2025 12:12 PM
To: CAS Community <cas-user@apereo.org>
Subject: Re: CAS 7.2.x Geolocation

I've turned up logging to trace and I see the following for both Azure and 
Maxmind services.

 <Geo location for [/x.x.x.x] is calculated as 
[GeoLocationResponse(addresses=[], latitude=0.0, longitude=0.0)]>

It looks like it's trying to resolve the geolocation, but it always returns 
0's.  Looking the IP up manually from the service of course returns the proper 
results.
Only thing I notice is there is a forward slash (/) in front of the IP address.

Thanks.

________________________________
From: AJ
Sent: Wednesday, June 25, 2025 10:03 AM
To: CAS Community <cas-user@apereo.org>
Subject: CAS 7.2.x Geolocation

Has anyone gotten geolocation data to actually be written to the events system 
without having to have user consent in their browsers?
I have tried various geo location services, Maxmind, IP, Azure and none of them 
work.  The only time it works is if the user is prompted in the browser and 
they accept.
I'm looking to capture geolocation data based on their IP address only.

I have these settings:

cas.tgc.geo-locate-client-session=true
cas.authn.adaptive.risk.geo-location.enabled=true
cas.authn.adaptive.risk.ip.enabled=true
cas.events.core.enabled=true
cas.events.core.track-geolocation=true
cas.geo-location.maxmind.city-database=/etc/cas/config/geodb/geoip-city.mmdb
cas.geo-location.maxmind.country-database=/etc/cas/config/geodb/geoip-country.mmdb

Obviously, I should not need user permission to just translate their IP to a 
geolocation.

If it matters, I am using MongoDB for event storage.

CAS version 7.2.3


-- 
- Website: https://apereo.github.io/cas
- List Guidelines: https://goo.gl/1VRrw7
- Contributions: https://goo.gl/mh7qDG
--- 
You received this message because you are subscribed to the Google Groups "CAS 
Community" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cas-user+unsubscr...@apereo.org.
To view this discussion visit 
https://groups.google.com/a/apereo.org/d/msgid/cas-user/MN6PR18MB54668327CD7CC82406D6B374DB45A%40MN6PR18MB5466.namprd18.prod.outlook.com.

Reply via email to