We are happy to announce that Vesta is back under active development as of 25 February 2024. We are working on Vesta 2.0 and expect to release it by the end of 2024. Read more about it: https://vestacp.com/docs/vesta-2-development
Помогите устранить ошибку Error: LetsEncrypt account registration 400
Помогите устранить ошибку Error: LetsEncrypt account registration 400
При редактировании домена ставлю 2 галочки - Поддержка SSL и Поддержка Lets Encrypt.
Нажимаю Сохранить, появляется сообщение Error: LetsEncrypt account registration 400.
Пробовал устанавливать это:
Пробовал в /etc/yum.conf указывать прокси, не помогает.
Пробовал в файл: /usr/local/vesta/bin/v-add-letsencrypt-user вместо
centos.6-vestacp-x86_64
vesta Версия:0.9.8 (x86_64) Релиз:17
Сервер перезагружал, домен удалял/добавлял, все без толку.
Нажимаю Сохранить, появляется сообщение Error: LetsEncrypt account registration 400.
Пробовал устанавливать это:
Но появляется ошибка:yum install vim-common
Trying other mirror.
Error: Cannot retrieve repository metadata (repomd.xml) for repository: inferno-el6. Please verify its path and try again
Это с параметров Enabled=0 в CentOS-Media.repohttp://repo.mrhost.biz/repo/6/x86_64/re ... repomd.xml: [Errno 14] PYCURL ERROR 22 - "The requested URL returned error: 403 Forbidden"
Пробовал в /etc/yum.conf указывать прокси, не помогает.
Пробовал в файл: /usr/local/vesta/bin/v-add-letsencrypt-user вместо
добавлятьagreement=$(curl -s -I "$api/terms" |grep Location |cut -f 2 -d \ |tr -d '\r\n')
Ничего не происходит.
centos.6-vestacp-x86_64
vesta Версия:0.9.8 (x86_64) Релиз:17
Сервер перезагружал, домен удалял/добавлял, все без толку.
Re: Помогите устранить ошибку Error: LetsEncrypt account registration 400
Изменился УРЛ agreement-а. Замените на https://letsencrypt.org/documents/LE-SA ... 5-2017.pdf
Должно помочь.
Должно помочь.
Re: Помогите устранить ошибку Error: LetsEncrypt account registration 400
linux81, спасибо, но не помогло или я что-то не правильно делаю.linux81 wrote:Изменился УРЛ agreement-а. Замените на https://letsencrypt.org/documents/LE-SA ... 5-2017.pdf
Должно помочь.
Вот так выглядит часть файла v-add-letsencrypt-user:
Code: Select all
#----------------------------------------------------------#
# Action #
#----------------------------------------------------------#
api='https://acme-v01.api.letsencrypt.org'
if [ -z "$email" ]; then
email=$(get_user_value '$CONTACT')
fi
agreement=$(curl -s -I "$api/terms" |grep Location |cut -f 2 -d \ |tr -d '\r\n')
# Generating key
key="$USER_DATA/ssl/user.key"
if [ ! -e "$key" ]; then
openssl genrsa -out $key $key_size >/dev/null 2>&1
chmod 600 $key
fi
# Defining key exponent
exponent=$(openssl pkey -inform perm -in "$key" -noout -text_pub |\
grep Exponent: |cut -f 2 -d '(' |cut -f 1 -d ')' |sed -e 's/x//' |\
xxd -r -p |encode_base64)
# Defining key modulus
modulus=$(openssl rsa -in "$key" -modulus -noout |\
sed -e 's/^Modulus=//' |xxd -r -p |encode_base64)
# Defining key thumb
thumb='{"e":"'$exponent'","kty":"RSA","n":"'"$modulus"'"}'
thumb="$(echo -n "$thumb" |openssl dgst -sha256 -binary |encode_base64)"
# Defining JWK header
header='{"e":"'$exponent'","kty":"RSA","n":"'"$modulus"'"}'
header='{"alg":"RS256","jwk":'"$header"'}'
# Requesting nonce
nonce=$(curl -s -I "$api/directory" |grep Nonce |cut -f 2 -d \ |tr -d '\r\n')
protected=$(echo -n '{"nonce":"'"$nonce"'"}' |encode_base64)
# Defining registration query
query='{"resource":"new-reg","contact":["mailto:'"$email"'"],'
query=$query'"agreement":"'$agreement'"}'
payload=$(echo -n "$query" |encode_base64)
signature=$(printf "%s" "$protected.$payload" |\
openssl dgst -sha256 -binary -sign "$key" |encode_base64)
data='{"header":'"$header"',"protected":"'"$protected"'",'
data=$data'"payload":"'"$payload"'","signature":"'"$signature"'"}'
# Sending request to LetsEncrypt API
answer=$(curl -s -i -d "$data" "$api/acme/new-reg")
status=$(echo "$answer" |grep HTTP/1.1 |tail -n1 |cut -f2 -d ' ')
# Checking http answer status
if [[ "$status" -ne "201" ]] && [[ "$status" -ne "409" ]]; then
check_result $E_CONNECT "LetsEncrypt account registration $status"
fi
Code: Select all
agreement=$(curl -s -I "$api/terms" |grep Location |cut -f 2 -d \ |tr -d '\r\n')
Code: Select all
agreement='https://letsencrypt.org/documents/LE-SA-v1.2-November-15-2017.pdf'
-
- Posts: 31
- Joined: Fri Apr 07, 2017 2:03 pm
Re: Помогите устранить ошибку Error: LetsEncrypt account registration 400
Решение (для моего случая)
1. Действие: Добавляю домен как сказано выше.
2. Результат: Ошибка. LetsEncrypt account registration 400
3. Причина: Домен зарегистрировал давно. Прописал Яндекс ДНС. В Почта для Домена не подключил. Соответственно, Lets Encrypt не может видеть записи в таблицах DNS сервера Яндекса.
4. Решение: Добавить домен в pdd.yandex.ru и подождать, пока обновятся записи.
5. Повторить пункт 1.