mirror of
https://github.com/thorsten-gehrig/alexa-remote-control.git
synced 2024-11-22 08:49:02 +01:00
Added support for Multi-Factor Authentication
Changed comment to use 'OTP' rather than 'HOTP'.
This commit is contained in:
parent
81ec828170
commit
21f3ab20d0
@ -402,7 +402,7 @@ ${CURL} ${OPTS} -s -c ${COOKIE} -b ${COOKIE} -A "${BROWSER}" -H "Accept-Language
|
||||
-H "$(grep 'Location: ' ${TMP}/.alexa.header | sed 's/Location: /Referer: /')" -d "@${TMP}/.alexa.postdata" https://www.${AMAZON}/ap/signin | grep "hidden" | sed 's/hidden/\n/g' | grep "value=\"" | sed -r 's/^.*name="([^"]+)".*value="([^"]+)".*/\1=\2\&/g' > "${TMP}/.alexa.postdata2"
|
||||
|
||||
#
|
||||
# add HOTP if using MFA
|
||||
# add OTP if using MFA
|
||||
#
|
||||
if [ ! -z "${MFA_SECRET}" ] ; then
|
||||
OTP=$(oathtool --base32 --totp "${MFA_SECRET}")
|
||||
|
@ -345,7 +345,7 @@ ${CURL} ${OPTS} -s -c ${COOKIE} -b ${COOKIE} -A "${BROWSER}" -H "Accept-Language
|
||||
-H "$(grep 'Location: ' ${TMP}/.alexa.header | sed 's/Location: /Referer: /')" -d "@${TMP}/.alexa.postdata" https://www.${AMAZON}/ap/signin | grep "hidden" | sed 's/hidden/\n/g' | grep "value=\"" | sed -r 's/^.*name="([^"]+)".*value="([^"]+)".*/\1=\2\&/g' > "${TMP}/.alexa.postdata2"
|
||||
|
||||
#
|
||||
# add HOTP if using MFA
|
||||
# add OTP if using MFA
|
||||
#
|
||||
if [ ! -z "${MFA_SECRET}" ] ; then
|
||||
OTP=$(oathtool --base32 --totp "${MFA_SECRET}")
|
||||
|
Loading…
Reference in New Issue
Block a user