hannesm / jackline

minimalistic secure XMPP client in OCaml
BSD 2-Clause "Simplified" License
251 stars 20 forks source link

signing up a new jabber id #12

Open hannesm opened 9 years ago

cfcs commented 9 years ago

What's the status on this one, is it still part of a release plan?

hannesm commented 9 years ago

it would be great, but I haven't had time to look into this right now...

cfcs commented 9 years ago

kindly bumping :-)

cfcs commented 8 years ago

For now, I'm using:

#!/bin/bash -eu
echo "Usage: $0 [server.org] [username] [password] | openssl s_client -starttls xmpp -connect [server]:5222" 1>&2

server="$1"
username="$2"
password="$3"

cat <<EOF
<?xml version='1.0'?><stream:stream to='${server}' version='1.0' xmlns:stream='http://etherx.jabber.org/streams' xmlns='jabber:client'>
<iq type='get' id='reg1' to='${server}'><query xmlns='jabber:iq:register'/></iq>
<iq type='set' id='purple$(head -c 4 /dev/urandom | xxd -ps)' to='${server}'><query xmlns='jabber:iq:register'><username>${username}</username><password>${password}</password></query></iq>
EOF
cat