summary refs log tree commit diff
path: root/bin
diff options
context:
space:
mode:
authorJune McEnroe <june@causal.agency>2021-10-04 10:49:09 -0400
committerJune McEnroe <june@causal.agency>2021-10-04 10:49:09 -0400
commit9b470ca58cfb5b4361ad602f03c781cdb9b1a52c (patch)
tree1f4536f9638fb01289af223d35e2f1a05575eb2d /bin
parentLimit Atom feed to 20 most recent entries (diff)
downloadsrc-9b470ca58cfb5b4361ad602f03c781cdb9b1a52c.tar.gz
src-9b470ca58cfb5b4361ad602f03c781cdb9b1a52c.zip
Fix lobsters/tildenews login
They started sending links with "&username=june" tacked on after
the token. Don't know why since if you load the form with just the
token in the URL it still knows your username, and it's not submitted
as a hidden field or anything, but whatever.
Diffstat (limited to 'bin')
-rw-r--r--bin/sup.sh2
1 files changed, 1 insertions, 1 deletions
diff --git a/bin/sup.sh b/bin/sup.sh
index 1772f312..a261cb7f 100644
--- a/bin/sup.sh
+++ b/bin/sup.sh
@@ -151,7 +151,7 @@ lobsters() {
 		git fetch-email -i -M Trash \
 			-F "${lobstersFrom}" -T "${email}" \
 			-S 'Reset your password' |
-		sed -n 's|^https://.*[?]token=\(.*\)|\1|p'
+		sed -n 's|^https://.*[?]token=\([^&]*\).*|\1|p'
 	)
 	echo 'Fetching CSRF token...'
 	csrf=$(