[FreeNX-kNX] openssl md5 vs md5sum

Raphael Lydia Bertoche rbertoche at cpti.cetuc.puc-rio.br
Thu Apr 17 03:56:51 UTC 2014


I had problems with that old bug that made all sessions id become
"(stdin)=".
http://mail.kde.org/pipermail/freenx-knx/2010-July/008964.html
This fix lacks a trailing | tr -d '\n', though.

Why is "openssl md5" still default for COMMAND_MD5SUM? Or is it just
opensuse's fault? This 0.7.3 looks aged.

Even if it's not default, it's so easy to fix, why not support both md5sum
and openssl md5?

I had only to do something like that every time COMMAND_MD5SUM was used:

@@ -352,7 +352,7 @@
                export DESKTOP_SHARING_IDS=""
                for i in $(LC_ALL=C netstat -ln --protocol=unix | egrep
'X11-unix/X[0-9]$' | sed 's/.*X\(.*\)/\1/g')
                do
-                       uniqueid=$(echo $[$RANDOM*$RANDOM] |
$COMMAND_MD5SUM | cut -d" " -f1 | tr "[a-z]" "[A-Z]")
+                       uniqueid=$(echo $[$RANDOM*$RANDOM] |
$COMMAND_MD5SUM | tr " " "\n" | egrep "^[[:xdigit:]]{32}$" | tr "[a-z]"
"[A-Z]" | tr -d '\n')
                        DESKTOP_SHARING_IDS="$DESKTOP_SHARING_IDS
$uniqueid=$i"
                        printf "%-7s %-16s %32s %8s %5s %-14s %-11s %s\n"
"$i" "vnc-local" "$uniqueid" "--------" "$udepth" "$(echo $3 | cut -d'x'
-f1,2)" "Running" "X$i (Local)" >> $TMPFILE
                done


Thanks
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/freenx-knx/attachments/20140417/56200f90/attachment.html>


More information about the FreeNX-kNX mailing list