You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@syncope.apache.org by "Francesco Chicchiriccò (Confluence)" <no...@apache.org> on 2022/03/18 08:33:50 UTC

[CONF] Apache Syncope > Upgrade from 2.1.10 to 2.1.11

|
[![](cid:avatar_78b9d98d15f2e9b7250a2887bcf9b144)](https://cwiki.apache.org/confluence/display/~ilgrosso?src=mail&src.mail.product=confluence-
server&src.mail.timestamp=1647592430199&src.mail.notification=com.atlassian.confluence.plugins.confluence-
content-notifications-plugin%3Apage-created-
notification&src.mail.recipient=8aa980874e36a1eb014e36a2c41679b9) | Francesco
Chicchiriccò **created** a page  
---|---  
|  
---  
|  | [![page icon](cid:page-
icon)](https://cwiki.apache.org/confluence/display/SYNCOPE/Upgrade+from+2.1.10+to+2.1.11?src=mail&src.mail.product=confluence-
server&src.mail.timestamp=1647592430199&src.mail.notification=com.atlassian.confluence.plugins.confluence-
content-notifications-plugin%3Apage-created-
notification&src.mail.recipient=8aa980874e36a1eb014e36a2c41679b9&src.mail.action=view
"page icon")  
---  
[Upgrade from 2.1.10 to
2.1.11](https://cwiki.apache.org/confluence/display/SYNCOPE/Upgrade+from+2.1.10+to+2.1.11?src=mail&src.mail.product=confluence-
server&src.mail.timestamp=1647592430199&src.mail.notification=com.atlassian.confluence.plugins.confluence-
content-notifications-plugin%3Apage-created-
notification&src.mail.recipient=8aa980874e36a1eb014e36a2c41679b9&src.mail.action=view
"Upgrade from 2.1.10 to 2.1.11")  
|

#

  * Source changes
    * POM
    * SQL

Source changes

## POM

In the root `pom.xml`:

  * change parent/version from 2.1.10 to 2.1.11
  * change properties/syncope.version from 2.1.10 to 2.1.11

## SQL

In case you are using security questions as part of the [password reset
flow](https://syncope.apache.org/docs/2.1/reference-guide.html#password-reset)
in your deployment, there are some relevant changes introduced by
[SYNCOPE-1666](https://issues.apache.org/jira/browse/SYNCOPE-1666) that are
requiring some manual database upgrade steps, as follows.

If you need more control you can even opt for a BASH or Python script that
generates data to write on the database. For example you can generate with
BASH terminale SHA2 strings as shown here: [https://beamtic.com/terminal-hash-
making](http://example.com/)

### PostgreSQL 12+:

<https://www.postgresql.org/docs/12/pgcrypto.html#id-1.11.7.34.5>

First of all, enable the via

    
    
    psql -U [pg_user] -d [pg_db_name] -c "CREATE EXTENSION pgcrypto;"

then run the following SQL statement:

    
    
    UPDATE syncopeuser SET securityanswer = encode(digest(securityanswer, 'sha256'), 'hex') where securityanswer is not null;
    

MySQL 8

<https://dev.mysql.com/doc/refman/8.0/en/encryption-functions.html>

    
    
    UPDATE syncopeuser SET securityanswer = SHA2(securityanswer, 256) where securityanswer is not null;
    

### Oracle

<https://docs.oracle.com/en/database/oracle/oracle-
database/12.2/arpls/DBMS_CRYPTO.html>

<https://docs.oracle.com/database/121/SQLRF/functions183.htm#SQLRF55647>

Sample SQL statement:

    
    
    UPDATE syncopeuser SET securityanswer = rawtohex(standard_hash ( securityanswer, 'SHA256')) where securityanswer is not null;
    

### SQLServer 2017+

<https://docs.microsoft.com/it-it/sql/t-sql/functions/hashbytes-transact-
sql?view=sql-server-ver15>

Sample SQL statement:

    
    
    UPDATE syncopeuser SET securityanswer = select CONVERT(VARCHAR(MAX), (SELECT HASHBYTES('SHA2_256',securityanswer)), 1) where securityanswer is not null;
    

  
  
  
---  
|  | [![View page Icon](cid:com.atlassian.confluence.plugins.confluence-email-
resources_view-page-email-adg-footer-
item_icon)](https://cwiki.apache.org/confluence/display/SYNCOPE/Upgrade+from+2.1.10+to+2.1.11?src=mail&src.mail.product=confluence-
server&src.mail.timestamp=1647592430199&src.mail.notification=com.atlassian.confluence.plugins.confluence-
content-notifications-plugin%3Apage-created-
notification&src.mail.recipient=8aa980874e36a1eb014e36a2c41679b9&src.mail.action=view
"View page Icon") | [View
page](https://cwiki.apache.org/confluence/display/SYNCOPE/Upgrade+from+2.1.10+to+2.1.11?src=mail&src.mail.product=confluence-
server&src.mail.timestamp=1647592430199&src.mail.notification=com.atlassian.confluence.plugins.confluence-
content-notifications-plugin%3Apage-created-
notification&src.mail.recipient=8aa980874e36a1eb014e36a2c41679b9&src.mail.action=view
"View page") | •  
---|---|---  
[![Like Icon](cid:com.atlassian.confluence.plugins.confluence-like_view-email-
adg-content-
item_icon)](https://cwiki.apache.org/confluence/plugins/likes/like.action?contentId=199539735&src=mail&src.mail.product=confluence-
server&src.mail.timestamp=1647592430199&src.mail.notification=com.atlassian.confluence.plugins.confluence-
content-notifications-plugin%3Apage-created-
notification&src.mail.recipient=8aa980874e36a1eb014e36a2c41679b9&src.mail.action=like&jwt=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzdWIiOiJ4c3JmOjhhYTk4MDg3NGUzNmExZWIwMTRlMzZhMmM0MTY3OWI5IiwicXNoIjoiOWE2YmZlZWRkYmVhNzk1ZmQ2NGNhYjdkMmFjNjMzZDE4OWI4NTA4ZTMzODA2N2ZiMGRjN2UyOTE2ZWY5YzlhZSIsImlzcyI6ImNvbmZsdWVuY2Vfbm90aWZpY2F0aW9uc0FSRUgtWFVEMS1QT1FHLUNTQU8iLCJleHAiOjE2NDgxOTcyMzAsImlhdCI6MTY0NzU5MjQzMH0.y1ijf9aUkbkVKhAuBY5YsAmHESg23LJh3Oyzsco2etA
"Like Icon") |
[Like](https://cwiki.apache.org/confluence/plugins/likes/like.action?contentId=199539735&src=mail&src.mail.product=confluence-
server&src.mail.timestamp=1647592430199&src.mail.notification=com.atlassian.confluence.plugins.confluence-
content-notifications-plugin%3Apage-created-
notification&src.mail.recipient=8aa980874e36a1eb014e36a2c41679b9&src.mail.action=like&jwt=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzdWIiOiJ4c3JmOjhhYTk4MDg3NGUzNmExZWIwMTRlMzZhMmM0MTY3OWI5IiwicXNoIjoiOWE2YmZlZWRkYmVhNzk1ZmQ2NGNhYjdkMmFjNjMzZDE4OWI4NTA4ZTMzODA2N2ZiMGRjN2UyOTE2ZWY5YzlhZSIsImlzcyI6ImNvbmZsdWVuY2Vfbm90aWZpY2F0aW9uc0FSRUgtWFVEMS1QT1FHLUNTQU8iLCJleHAiOjE2NDgxOTcyMzAsImlhdCI6MTY0NzU5MjQzMH0.y1ijf9aUkbkVKhAuBY5YsAmHESg23LJh3Oyzsco2etA
"Like")  
---|---  
  
|  | [Stop watching
space](https://cwiki.apache.org/confluence/users/removespacenotification.action?spaceKey=SYNCOPE&src=mail&src.mail.product=confluence-
server&src.mail.timestamp=1647592430199&src.mail.notification=com.atlassian.confluence.plugins.confluence-
content-notifications-plugin%3Apage-created-
notification&src.mail.recipient=8aa980874e36a1eb014e36a2c41679b9&src.mail.action=stop-
watching&jwt=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzdWIiOiJ4c3JmOjhhYTk4MDg3NGUzNmExZWIwMTRlMzZhMmM0MTY3OWI5IiwicXNoIjoiOTFhMzk4NWI0MDM3MTk3OTgzNzJhZmRlYjFiNjJlZTkyOWJiNzU3MDQ2NjFhOGM2N2U2OTNmMzViYjM5YzA0OCIsImlzcyI6ImNvbmZsdWVuY2Vfbm90aWZpY2F0aW9uc0FSRUgtWFVEMS1QT1FHLUNTQU8iLCJleHAiOjE2NDgxOTcyMzAsImlhdCI6MTY0NzU5MjQzMH0.hTR8l3zhMfxImZBTQ7e49lGFENza2dsd0ozb-
HwmSyA) | •  
---|---  
[Manage
notifications](https://cwiki.apache.org/confluence/users/editmyemailsettings.action?src=mail&src.mail.product=confluence-
server&src.mail.timestamp=1647592430199&src.mail.notification=com.atlassian.confluence.plugins.confluence-
content-notifications-plugin%3Apage-created-
notification&src.mail.recipient=8aa980874e36a1eb014e36a2c41679b9&src.mail.action=manage)  
---  
| ![Confluence logo big](cid:footer-desktop-logo)  
---  
This message was sent by Atlassian Confluence 7.13.2  
![](cid:footer-mobile-logo)  
---