Skip to content

Commit

Permalink
Fix bug 71592 – Replace trust auth with secure method (#135)
Browse files Browse the repository at this point in the history
Reviewed-on: https://git.onlyoffice.com/ONLYOFFICE/DocSpace-buildtools/pulls/135
Co-authored-by: Vladimir Ischenko <[email protected]>
Co-committed-by: Vladimir Ischenko <[email protected]>
  • Loading branch information
isboston authored and evgeniy-antonyuk committed Jan 10, 2025
1 parent a2a1f92 commit f95f9a8
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
3 changes: 0 additions & 3 deletions install/OneClickInstall/install-RedHat/install-app.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,6 @@ cat<<EOF
EOF

sed "/host\s*all\s*all\s*127\.0\.0\.1\/32\s*ident$/s|ident$|trust|" -i /var/lib/pgsql/data/pg_hba.conf
sed "/host\s*all\s*all\s*::1\/128\s*ident$/s|ident$|trust|" -i /var/lib/pgsql/data/pg_hba.conf

for SVC in $package_services; do
systemctl start $SVC
systemctl enable $SVC
Expand Down
3 changes: 3 additions & 0 deletions install/OneClickInstall/install-RedHat/install-preq.sh
Original file line number Diff line number Diff line change
Expand Up @@ -106,6 +106,9 @@ if [[ $PSQLExitCode -eq $UPDATE_AVAILABLE_CODE ]]; then
fi
postgresql-setup initdb || true

sed -E -i "s/(host\s+(all|replication)\s+all\s+(127\.0\.0\.1\/32|\:\:1\/128)\s+)(ident|trust|md5)/\1scram-sha-256/" /var/lib/pgsql/data/pg_hba.conf
sed -i "s/^#\?password_encryption = .*/password_encryption = 'scram-sha-256'/" /var/lib/pgsql/data/postgresql.conf

if ! command -v semanage &> /dev/null; then
yum install -y policycoreutils-python || yum install -y policycoreutils-python-utils
fi
Expand Down

0 comments on commit f95f9a8

Please sign in to comment.