в моей компании есть несколько экземпляров, которые используются в качестве бэкэндов для производства, тестирования и других целей. Я тоже новый сотрудник в компании. В последнее время все экземпляры внезапно не могут получать обновления с помощью git или apt-get.
git fetch --all
, результат:fatal: unable to access 'https://[...].git/': server certificate verification failed. CAfile: /etc/ssl/certs/ca-certificates.crt CRLfile: none
После того, как я увидел пост , я снова использую git config --global http.sslverify false
и git fetch all
. результат:
fatal: unable to access 'https://[...].git/': The requested URL returned error: 403
error: Could not fetch origin
Это очень странно, потому что я не знаю, связана ли это с сертификацией или с правами пользователя. Или просто в конце это проблема сертификации.
sudo apt-get update
в этой ссылке. Когда я использую sudo apt-get update
, возникает множество ошибок:Ign:1 http://dl.google.com/linux/chrome/deb stable InRelease
Ign:2 http://dl.google.com/linux/chrome/deb stable Release
Ign:3 http://dl.google.com/linux/chrome/deb stable/main amd64 Packages.diff/Index
Ign:4 http://dl.google.com/linux/chrome/deb stable/main all Packages
Ign:5 http://dl.google.com/linux/chrome/deb stable/main Translation-en
Ign:6 http://dl.google.com/linux/chrome/deb stable/main amd64 Packages
Ign:4 http://dl.google.com/linux/chrome/deb stable/main all Packages
...
...
...
Ign:155 https://esm.ubuntu.com/infra/ubuntu xenial-infra-security/main i386 Packages
Ign:147 https://esm.ubuntu.com/infra/ubuntu xenial-infra-security/main all Packages
Ign:149 https://esm.ubuntu.com/infra/ubuntu xenial-infra-security/main Translation-en
Ign:156 https://esm.ubuntu.com/infra/ubuntu xenial-infra-updates/main amd64 Packages
Ign:157 https://esm.ubuntu.com/infra/ubuntu xenial-infra-updates/main i386 Packages
Ign:152 https://esm.ubuntu.com/infra/ubuntu xenial-infra-updates/main all Packages
Ign:153 https://esm.ubuntu.com/infra/ubuntu xenial-infra-updates/main Translation-en
Err:154 https://esm.ubuntu.com/infra/ubuntu xenial-infra-security/main amd64 Packages
server certificate verification failed. CAfile: /etc/ssl/certs/ca-certificates.crt CRLfile: none
Ign:155 https://esm.ubuntu.com/infra/ubuntu xenial-infra-security/main i386 Packages
Err:156 https://esm.ubuntu.com/infra/ubuntu xenial-infra-updates/main amd64 Packages
server certificate verification failed. CAfile: /etc/ssl/certs/ca-certificates.crt CRLfile: none
Ign:157 https://esm.ubuntu.com/infra/ubuntu xenial-infra-updates/main i386 Packages
Reading package lists... Done
W: The repository 'http://dl.google.com/linux/chrome/deb stable Release' does not have a Release file.
N: Data from such a repository can't be authenticated and is therefore potentially dangerous to use.
N: See apt-secure(8) manpage for repository creation and user configuration details.
W: The repository 'http://hk.archive.ubuntu.com/ubuntu xenial Release' does not have a Release file.
N: Data from such a repository can't be authenticated and is therefore potentially dangerous to use.
N: See apt-secure(8) manpage for repository creation and user configuration details.
W: The repository 'http://hk.archive.ubuntu.com/ubuntu xenial-updates Release' does not have a Release file.
N: Data from such a repository can't be authenticated and is therefore potentially dangerous to use.
N: See apt-secure(8) manpage for repository creation and user configuration details.
W: The repository 'https://download.docker.com/linux/ubuntu xenial Release' does not have a Release file.
N: Data from such a repository can't be authenticated and is therefore potentially dangerous to use.
N: See apt-secure(8) manpage for repository creation and user configuration details.
W: The repository 'http://hk.archive.ubuntu.com/ubuntu xenial-backports Release' does not have a Release file.
N: Data from such a repository can't be authenticated and is therefore potentially dangerous to use.
N: See apt-secure(8) manpage for repository creation and user configuration details.
W: The repository 'http://security.ubuntu.com/ubuntu xenial-security Release' does not have a Release file.
N: Data from such a repository can't be authenticated and is therefore potentially dangerous to use.
N: See apt-secure(8) manpage for repository creation and user configuration details.
W: The repository 'http://ppa.launchpad.net/certbot/certbot/ubuntu xenial Release' does not have a Release file.
N: Data from such a repository can't be authenticated and is therefore potentially dangerous to use.
N: See apt-secure(8) manpage for repository creation and user configuration details.
W: The repository 'http://ppa.launchpad.net/deadsnakes/ppa/ubuntu xenial Release' does not have a Release file.
N: Data from such a repository can't be authenticated and is therefore potentially dangerous to use.
N: See apt-secure(8) manpage for repository creation and user configuration details.
W: The repository 'https://esm.ubuntu.com/infra/ubuntu xenial-infra-security Release' does not have a Release file.
N: Data from such a repository can't be authenticated and is therefore potentially dangerous to use.
N: See apt-secure(8) manpage for repository creation and user configuration details.
W: The repository 'https://esm.ubuntu.com/infra/ubuntu xenial-infra-updates Release' does not have a Release file.
N: Data from such a repository can't be authenticated and is therefore potentially dangerous to use.
N: See apt-secure(8) manpage for repository creation and user configuration details.
E: Failed to fetch http://dl.google.com/linux/chrome/deb/dists/stable/main/binary-amd64/Packages 403 Forbidden [IP: 142.251.220.78 80]
E: Failed to fetch http://hk.archive.ubuntu.com/ubuntu/dists/xenial-backports/restricted/binary-amd64/Packages 403 Forbidden [IP: 45.125.0.6 80]
E: Failed to fetch http://hk.archive.ubuntu.com/ubuntu/dists/xenial/main/binary-amd64/Packages 403 Forbidden [IP: 45.125.0.6 80]
E: Failed to fetch https://download.docker.com/linux/ubuntu/dists/xenial/stable/binary-amd64/Packages server certificate verification failed. CAfile: /etc/ssl/certs/ca-certificates.crt CRLfile: none
E: Failed to fetch http://hk.archive.ubuntu.com/ubuntu/dists/xenial-updates/main/binary-amd64/Packages 403 Forbidden [IP: 45.125.0.6 80]
E: Failed to fetch http://security.ubuntu.com/ubuntu/dists/xenial-security/main/binary-amd64/Packages 403 Forbidden [IP: 91.189.91.82 80]
E: Failed to fetch http://ppa.launchpad.net/deadsnakes/ppa/ubuntu/dists/xenial/main/binary-amd64/Packages 403 Forbidden [IP: 185.125.190.80 80]
E: Failed to fetch http://ppa.launchpad.net/certbot/certbot/ubuntu/dists/xenial/main/binary-amd64/Packages 403 Forbidden [IP: 185.125.190.80 80]
E: Failed to fetch https://esm.ubuntu.com/infra/ubuntu/dists/xenial-infra-security/main/binary-amd64/Packages server certificate verification failed. CAfile: /etc/ssl/certs/ca-certificates.crt CRLfile: none
E: Failed to fetch https://esm.ubuntu.com/infra/ubuntu/dists/xenial-infra-updates/main/binary-amd64/Packages server certificate verification failed. CAfile: /etc/ssl/certs/ca-certificates.crt CRLfile: none
E: Some index files failed to download. They have been ignored, or old ones used instead.
Я буду очень признателен, если кто-нибудь сможет дать мне несколько подсказок/решений, потому что я работал над этими проблемами несколько дней! Это Ubuntu 16.04.7 LTS, наша команда использовала Let's Encrypt для сертификата, большое спасибо.
Настройка git config --global http.sslverify false
для участия в git: по этой ссылке
sudo apt-get update
упоминается в:
эта ссылка
Похоже, проблемы с фаерволом. Возможно, прошивка взламывает шифрование, чтобы проверить пакеты. После проверки пакет снова шифруется новым внутренним сертификатом. Если он не установлен в системе, появится ошибка.
Тест:
ssh -vvv [User]@[URL]
Обходной путь:
Спасибо! это действительно проблема с брандмауэром
Вы маршрутизируете этот трафик через прокси? (Также:
git config http.sslverify false
, с--global
или без него, является чрезвычайно опасным инструментом. Не используйте его легкомысленно.)