Ondrej Svačina ( 
https://osgeo-org.atlassian.net/secure/ViewProfile.jspa?accountId=60b3beaebbe237006acb3d97
 ) *created* an issue

GeoServer ( 
https://osgeo-org.atlassian.net/browse/GEOS?atlOrigin=eyJpIjoiYjI0MzhiYTNjNmJiNGQ2Njg3YjA0ZDdkZTY3ZTQyNzQiLCJwIjoiaiJ9
 ) / Bug ( 
https://osgeo-org.atlassian.net/browse/GEOS-10084?atlOrigin=eyJpIjoiYjI0MzhiYTNjNmJiNGQ2Njg3YjA0ZDdkZTY3ZTQyNzQiLCJwIjoiaiJ9
 ) GEOS-10084 ( 
https://osgeo-org.atlassian.net/browse/GEOS-10084?atlOrigin=eyJpIjoiYjI0MzhiYTNjNmJiNGQ2Njg3YjA0ZDdkZTY3ZTQyNzQiLCJwIjoiaiJ9
 ) Cannot save the custom SQL session start script when using braces "{}" 
together with the ${GSUSER,geoserver} ( 
https://osgeo-org.atlassian.net/browse/GEOS-10084?atlOrigin=eyJpIjoiYjI0MzhiYTNjNmJiNGQ2Njg3YjA0ZDdkZTY3ZTQyNzQiLCJwIjoiaiJ9
 )

Issue Type: Bug Affects Versions: 2.19.0 Assignee: Unassigned Created: 
30/May/21 6:49 PM Priority: Medium Reporter: Ondrej Svačina ( 
https://osgeo-org.atlassian.net/secure/ViewProfile.jspa?accountId=60b3beaebbe237006acb3d97
 )

There is a bug probably in the parser of the custom SQL session start/stop 
script ( 
https://docs.geoserver.org/latest/en/user/data/database/sqlsession.html ) of 
the data source.

If you use braces in the script, for example:
 {{ select set_config('my.userString', substring('$

{GSUSER,geoserver}', 'user#" [0-9] {5}#"%', '#'), false) }} 
the saving fails with the
Already found a ${ sequence before the one at 83

If you do not use the braces in the Postgres regex, e.g.:
 {{ select set_config('my.userString', substring('${GSUSER,geoserver}

', 'user#" [0-9] #"%', '#'), false) }} 

the save operation is successful.

This is an evident bug because the braces in the regex have nothing to do with 
the GeoSever variable.

( 
https://osgeo-org.atlassian.net/browse/GEOS-10084#add-comment?atlOrigin=eyJpIjoiYjI0MzhiYTNjNmJiNGQ2Njg3YjA0ZDdkZTY3ZTQyNzQiLCJwIjoiaiJ9
 ) Add Comment ( 
https://osgeo-org.atlassian.net/browse/GEOS-10084#add-comment?atlOrigin=eyJpIjoiYjI0MzhiYTNjNmJiNGQ2Njg3YjA0ZDdkZTY3ZTQyNzQiLCJwIjoiaiJ9
 )

Get Jira notifications on your phone! Download the Jira Cloud app for Android ( 
https://play.google.com/store/apps/details?id=com.atlassian.android.jira.core&referrer=utm_source%3DNotificationLink%26utm_medium%3DEmail
 ) or iOS ( 
https://itunes.apple.com/app/apple-store/id1006972087?pt=696495&ct=EmailNotificationLink&mt=8
 ) This message was sent by Atlassian Jira (v1001.0.0-SNAPSHOT#100165- 
sha1:3611a76 )
_______________________________________________
Geoserver-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/geoserver-devel

Reply via email to