Distributed Peer-to-Peer Web Search Engine and Intranet Search Appliance
Java decentralizedintranet-searchintranet-search-enginep2pp2p-networkprivacyprivacy-protectionsearch-enginesearchenginewebweb-search-enginewebsearchwebseearch-engine
do better documentation on how to set a default password
Michael Peter Christen36e616271b97
diff --git a/docker/Dockerfile b/docker/Dockerfileindex 929cb6b9f..d8f19c7d5 100644--- a/docker/Dockerfile+++ b/docker/Dockerfile@@ -35,6 +35,7 @@ RUN apt-get update && \RUN \# Set initial admin password : "docker" (encoded with custom yacy md5 function net.yacy.cora.order.Digest.encodeMD5Hex())+# > java -classpath classes net.yacy.cora.order.Digest -strfhex "admin:The YaCy access is limited to administrators. If you don't know the password, you can change it using <yacy-home>/bin/passwd.sh <new-password>:docker"sed -i "/adminAccountBase64MD5=/c\adminAccountBase64MD5=MD5:e672161ffdce91be4678605f4f4e6786" /opt/yacy_search_server/defaults/yacy.init && \# Intially enable HTTPS : this is the most secure option for remote administrator authenticationsed -i "/server.https=false/c\server.https=true" /opt/yacy_search_server/defaults/yacy.init && \@@ -46,7 +47,7 @@ RUN \# Expose HTTP and HTTPS default portsEXPOSE 8090 8443-# Set data volume : yacy data and configuration will persist aven after container stop or destruction+# Set data volume : yacy data and configuration will persist even after container stop or destructionVOLUME ["/opt/yacy_search_server/DATA"]# Next commands run as yacy as non-root user for improved securitydiff --git a/source/net/yacy/cora/order/Digest.java b/source/net/yacy/cora/order/Digest.javaindex 749692d46..9ba42552e 100644--- a/source/net/yacy/cora/order/Digest.java+++ b/source/net/yacy/cora/order/Digest.java@@ -26,6 +26,7 @@ import java.io.FileInputStream;import java.io.IOException;import java.io.InputStream;import java.io.RandomAccessFile;+import java.nio.charset.StandardCharsets;import java.security.MessageDigest;import java.security.NoSuchAlgorithmException;import java.util.Queue;@@ -132,7 +133,7 @@ public class Digest {digest.reset(); // they should all be reseted but anyway; this is safe}byte[] keyBytes;- keyBytes = UTF8.getBytes(key);+ keyBytes = key.getBytes(StandardCharsets.UTF_8);digest.update(keyBytes);final byte[] result = digest.digest();digest.reset(); // to be prepared for next