#49233 closed defect (fixed)
selfupdate fails with "Failed to verify signature for MacPorts source"
Reported by: | micrology | Owned by: | admin@… |
---|---|---|---|
Priority: | High | Milestone: | |
Component: | server/hosting | Version: | 2.3.3 |
Keywords: | Cc: | iqgrande, sandym (Sandy Martel), dbarter@…, NeilGirdhar (Neil), ryandesign (Ryan Carsten Schmidt), EnekoGotzon, rubendibattista (Ruben Di Battista), rhett.lhy@…, gsulshski (Greg Ulsh), rnspayne@…, jimmymbreen@…, hapaguy (Brian Kurt Fujikawa), js9986@…, macports@…, andy@…, moderndeveloperllc (Mark Garrett), chihangli@…, epaell, tpmanojm@…, mjhsieh@…, witoldj@…, fabian.glaser@…, Miroboru (Tor Andre Myrvoll), mndavidoff (Monte Davidoff), farmer.tseng@…, gallafent, roman.dayneko@…, seb@…, kurtjaeke@…, a.vincelli@…, robin.newman@…, djlambert (Derek J. Lambert), neurodroid (Christoph Schmidt-Hieber), avysk (Alexey Vyskubov), peter.mcalpine@…, m1@…, MaurizioLoreti, joaogeada (Joao Geada), john@…, szibetti@…, mjwybrow (Michael Wybrow), moritz.peter@…, leeawalsh@…, glen@…, deesto (John S. De Stefano Jr.), smparkes@…, vcultharris (L.T. Harris), alan.mock@…, grimreaper (Eitan Adler), morrell@…, bunk3m (Bunk3m), absima@…, steve.sell@…, tiasus@…, smeingast (Stefan Meingast), nortcele, aoeumacports@…, zaxdo@…, thomas.gimpel@…, netgamer7 (Roger Ward), raju.apm@…, mcglk (Ken McGlothlen), stephenhamilton@…, eddieh (Eddie Hillenbrand), macports@…, samuel.hofmann@…, rodolphefouquet@…, erich3@…, ClintO (Clint O), michaelwallis@…, p.fabrizio.salvatore@…, pe8ter@…, alandir2@…, 0xced (Cédric Luthi), eric.lebigot@…, macports@…, kngspook@…, jackh48@…, anthony@…, boehm.adam@…, p.perroud@…, axet (Alexey Kuznetsov), todmorrison (Tod Morrison), permezel@…, macports@…, r1pp3r@…, suneilp@…, meckiemac@…, persramd@…, mkikkawa@…, petermisak (Peter Misak), pmo@…, Stochasticus@…, bodait, neilt (Neil Tiffin), stromnov (Andrey Stromnov), matt@…, summers@…, jsalort (Julien Salort), edgtzolvera@…, rohall@…, Feuermurmel (Michael Schwarz), tk7r (Thomas Kotzian), fracai, help@…, davidwalton3142@…, macports@…, jasonw@…, vosslab (Neil Voss), majoc-at-astro (majoc-at-astro), texas-swift (Spencer Swift), jmgoicolea (Jose Goicolea), j.albarran@…, eschnett (Erik Schnetter), H3ik0, bhadder@…, ktitt27@…, marco.outatime@…, josephaw@…, marco-comini (Marco Comini), skymoo (Adam Mercer), deyv@…, macports.org@…, macuserguru | |
Port: |
Description
The output from sudo port -v selfupdate is:
---> Updating MacPorts base sources using rsync receiving file list ... done sent 36 bytes received 69 bytes 42.00 bytes/sec total size is 27013120 speedup is 257267.81 receiving file list ... done sent 36 bytes received 76 bytes 44.80 bytes/sec total size is 512 speedup is 4.57 Error: Failed to verify signature for MacPorts source! To report a bug, follow the instructions in the guide: http://guide.macports.org/#project.tickets Error: /opt/local/bin/port: port selfupdate failed: Failed to verify signature for MacPorts source!
This is using MacPort 2.3.3 on Yosemite. It worked last time I did it, about 2 weeks ago.
The source listed in /opt/local/etc/macports/sources.conf is:
rsync://rsync.macports.org/release/tarballs/ports.tar [default]
Change History (179)
comment:1 follow-up: 144 Changed 9 years ago by mherdeg@…
comment:2 Changed 9 years ago by ryandesign (Ryan Carsten Schmidt)
Cc: | iqgrande@… sandy@… dbarter@… mistersheik@… ryandesign@… added |
---|---|
Keywords: | selfupdate removed |
comment:3 follow-up: 127 Changed 9 years ago by ryandesign (Ryan Carsten Schmidt)
Until the rsync server is fixed, you can update MacPorts by downloading the appropriate OS-X-version-specific installer from the MacPorts web site. This will not erase your installed ports.
I did not see one, but if you see an error message at the end of the installer when it tries to contact the rsync server, you can ignore it; MacPorts should still have been successfully updated, which you can verify by typing "port version".
comment:5 Changed 9 years ago by rubendibattista (Ruben Di Battista)
Cc: | rubendibattista@… added |
---|
Cc Me!
comment:6 Changed 9 years ago by ryandesign (Ryan Carsten Schmidt)
Cc: | rhett.lhy@… gsulsh57@… added |
---|
comment:8 Changed 9 years ago by ryandesign (Ryan Carsten Schmidt)
Cc: | jimmymbreen@… added |
---|---|
Component: | base → server/hosting |
Owner: | changed from macports-tickets@… to admin@… |
Has duplicate #49243.
comment:9 Changed 9 years ago by Ionic (Mihai Moldovan)
Please use sudo port sync
to synchronize your ports tree if a base upgrade is not necessary for the time being.
The selfupdate
operation is a "base upgrade" + "sync" operation at once.
comment:10 Changed 9 years ago by jmroot (Joshua Root)
base.tar.rmd160 was created about half an hour before base.tar, so it's from the previous update run.
ports.tar and ports.tar.rmd160 are from the same update run, so can be verified, but they're stale.
comment:14 Changed 9 years ago by ryandesign (Ryan Carsten Schmidt)
Cc: | farmer.tseng@… added |
---|
Has duplicate #49244.
comment:15 Changed 9 years ago by ryandesign (Ryan Carsten Schmidt)
Cc: | andy@… mark@… added |
---|
Has duplicate #49245.
comment:18 Changed 9 years ago by andy@…
How long should "sudo port sync" take to run? It's been going nearly 15 minutes with only the "---> Updating the ports tree" message. This is longer than it took to download the installation package.
comment:19 Changed 9 years ago by ryandesign (Ryan Carsten Schmidt)
The rsync server is broken; trying to use it is pointless until the administrator fixes it.
comment:24 follow-up: 26 Changed 9 years ago by ryandesign (Ryan Carsten Schmidt)
Cc: | fabian.glaser@… myrvoll@… added |
---|
Has duplicate #49249.
comment:26 follow-up: 27 Changed 9 years ago by fabian.glaser@…
Replying to ryandesign@…:
Has duplicate #49249.
I see that there is the same complaint several times, but I still dont' understand how to solve the problem, sync is working fine in my mac, and the following works
==> sudo port sync Password: ---> Updating the ports tree
So what I need to do?
Thansk a lot,
Fabian
comment:27 Changed 9 years ago by ryandesign (Ryan Carsten Schmidt)
Replying to fabian.glaser@…:
Replying to ryandesign@…:
Has duplicate #49249.
I see that there is the same complaint several times, but I still dont' understand how to solve the problem, sync is working fine in my mac, and the following works
==> sudo port sync Password: ---> Updating the ports tree
This ticket is about selfupdate failure. #49224 is about sync failure. They're both caused by the same server problem, and it affects all users that use the rsync server, which MacPorts does by default, so this affects most MacPorts users.
If your sources.conf lists rsync://rsync.macports.org/release/tarballs/ports.tar then sync will finish without error, but you will not actually receive any updates newer than the time the server broke. If your sources.conf lists rsync://rsync.macports.org/release/ports/ then sync will fail and display errors.
So what I need to do?
Wait until the administrator fixes the rsync server, or configure MacPorts to sync using svn instead.
comment:34 follow-up: 82 Changed 9 years ago by seb@…
I can't measure the importance of the .pem file, but it seems the openssl check is in bad state.
I sugget a (temporary) workaround:
Edit /opt/local/libexec/macports/lib/macports1.0/macports.tcl
On lines 3429/3430 you'll find:
ui_debug "failed verification with key $pubkey"
ui_debug "openssl output: $result"
Add this command:
set verified 1
And maybe (if you want to remember)
ui_debug "But i take my chance"
comment:79 Changed 9 years ago by rodolphefouquet@…
comment:82 follow-up: 106 Changed 9 years ago by neverpanic (Clemens Lang)
Replying to seb@…:
I sugget a (temporary) workaround:
Edit /opt/local/libexec/macports/lib/macports1.0/macports.tcl
On lines 3429/3430 you'll find:
ui_debug "failed verification with key $pubkey"
ui_debug "openssl output: $result"Add this command:
set verified 1
And maybe (if you want to remember)
ui_debug "But i take my chance"
This is a bad idea, because it breaks the chain of trust that normally ensures the macports update has not been tampered with. If your version of MacPorts is outdated, it is a much better idea to download one of the installers, because those are signed with an Apple Developer ID. Running this installer will only update MacPorts itself and leave your installed ports as-is.
comment:85 Changed 9 years ago by ryandesign (Ryan Carsten Schmidt)
Cc: | fritzs@… clint.olsen@… michaelwallis@… p.fabrizio.salvatore@… pe8ter@… added |
---|
comment:91 follow-up: 96 Changed 9 years ago by kngspook@…
So...what's the plan for this? Has anyone reached out to the sysadmin?
comment:96 Changed 9 years ago by ryandesign (Ryan Carsten Schmidt)
Replying to kngspook@…:
So...what's the plan for this? Has anyone reached out to the sysadmin?
The plan is for the administrator to fix the server. The administrator is assigned to this ticket, meaning he receives an email notification for every comment entered here. I also spoke directly with his manager today.
comment:106 Changed 9 years ago by seb@…
Replying to cal@…:
Replying to seb@…:
I sugget a (temporary) workaround:
Edit /opt/local/libexec/macports/lib/macports1.0/macports.tcl
On lines 3429/3430 you'll find:
ui_debug "failed verification with key $pubkey"
ui_debug "openssl output: $result"Add this command:
set verified 1
And maybe (if you want to remember)
ui_debug "But i take my chance"
This is a bad idea, because it breaks the chain of trust that normally ensures the macports update has not been tampered with. If your version of MacPorts is outdated, it is a much better idea to download one of the installers, because those are signed with an Apple Developer ID. Running this installer will only update MacPorts itself and leave your installed ports as-is.
I'm not sure you're right. Because as far as i can understand, the line wich is impacted by the test is only a "ssh key" validation. It does not contain any "mac port" data. All the data that are synchronized before and after seem to work with dependencies for me. If what you say is correct, it would mean macport does not have really establish an "El Capitan" "chain of trust". If what i guess is true, it's only an ssh key wich is incorrectly built from the admin. Anyway, i needed my macports yesterday to build my application. It worked fine for me ;)
comment:107 Changed 9 years ago by persramd@…
On getting the following error: Error: /opt/local/bin/port: port selfupdate failed: Failed to verify signature for MacPorts source! ...
I tried the above fix. With it, I was able to selfupdate.
However, now (with the temp fix still in place), when I try to upgrade outdated, I get a new error. ,shown below. Apologies for including all this text in here. I am not sure where to put it in this message.
(Removed by admin. File a separate ticket against ld64-latest, and add log as an attachment, don't paste it into a comment.)
comment:112 Changed 9 years ago by Quibi (Quibizo)
When I try
sudo port -vdt sync
I get the following errors:
---> Updating the ports tree Synchronizing local ports tree from rsync://rsync.macports.org/release/tarballs/ports.tar DEBUG: /usr/bin/rsync -rtzv --delete-after rsync://rsync.macports.org/release/tarballs/ports.tar /opt/local/var/macports/sources/rsync.macports.org/release/tarballs receiving file list ... done sent 36 bytes received 70 bytes 70.67 bytes/sec total size is 62720000 speedup is 591698.11 DEBUG: /usr/bin/rsync -rtzv --delete-after rsync://rsync.macports.org/release/tarballs/ports.tar.rmd160 /opt/local/var/macports/sources/rsync.macports.org/release/tarballs receiving file list ... done sent 36 bytes received 77 bytes 45.20 bytes/sec total size is 512 speedup is 4.53 DEBUG: successful verification with key /opt/local/share/macports/macports-pubkey.pem DEBUG: /usr/bin/tar -C /opt/local/var/macports/sources/rsync.macports.org/release/tarballs/tmp -xf /opt/local/var/macports/sources/rsync.macports.org/release/tarballs/ports.tar DEBUG: /usr/bin/rsync -rtzv --delete-after rsync://rsync.macports.org/release/tarballs/PortIndex_darwin_15_i386/PortIndex /opt/local/var/macports/sources/rsync.macports.org/release/tarballs receiving file list ... rsync: change_dir "tarballs/PortIndex_darwin_15_i386" (in release) failed: No such file or directory (2) done sent 4 bytes received 9 bytes 8.67 bytes/sec total size is 0 speedup is 0.00 rsync error: some files could not be transferred (code 23) at /BuildRoot/Library/Caches/com.apple.xbs/Sources/rsync/rsync-47/rsync/main.c(1400) [receiver=2.6.9] Command failed: /usr/bin/rsync -rtzv --delete-after rsync://rsync.macports.org/release/tarballs/PortIndex_darwin_15_i386/PortIndex /opt/local/var/macports/sources/rsync.macports.org/release/tarballs Exit code: 23 DEBUG: Synchronization of the PortIndex failed doing rsync Creating port index in /opt/local/var/macports/sources/rsync.macports.org/release/tarballs/ports
Sorry if this an useless information.
comment:119 Changed 9 years ago by macubergeek@…
Just did port selfupdate and had this error like many before me:
Error: Failed to verify signature for MacPorts source! Please run `port -v selfupdate' for details. Error: /opt/local/bin/port: port selfupdate failed: Failed to verify signature for MacPorts source! ---> Updating MacPorts base sources using rsync receiving file list ... done sent 36 bytes received 69 bytes 70.00 bytes/sec total size is 27013120 speedup is 257267.81 receiving file list ... done sent 36 bytes received 76 bytes 74.67 bytes/sec total size is 512 speedup is 4.57 Error: Failed to verify signature for MacPorts source! To report a bug, follow the instructions in the guide: http://guide.macports.org/#project.tickets Error: /opt/local/bin/port: port selfupdate failed: Failed to verify signature for MacPorts source!
comment:127 follow-up: 151 Changed 9 years ago by macubergeek@…
Replying to ryandesign@…:
Until the rsync server is fixed, you can update MacPorts by downloading the appropriate OS-X-version-specific installer from the MacPorts web site. This will not erase your installed ports.
I did not see one, but if you see an error message at the end of the installer when it tries to contact the rsync server, you can ignore it; MacPorts should still have been successfully updated, which you can verify by typing "port version".
Tried this but it didn't fix the problem. Still getting error Error: /opt/local/bin/port: port selfupdate failed: Failed to verify signature for MacPorts source!
comment:144 Changed 9 years ago by ktitt27@…
Replying to mherdeg@…:
This problem repros for me using OS X 10.11 and the latest stable "MacPorts-2.3.4-10.11". ...
As he already mentioned, it has also come to my attention that MacPorts-2.3.4 on OSX 10.11 causes the same issue.
comment:148 Changed 9 years ago by StanSanderson
Cc: | stansand@… removed |
---|
comment:151 Changed 9 years ago by jharmon@…
it doesn't solve the selfupdate problem. what it does is updates your macports version. THEN you have to use port sync to update your tree, and can carry on. the only thing that is broken is updating the macports application itself, which is normally done during a self update IN ADDITION to port sync
Replying to macubergeek@…:
Replying to ryandesign@…:
Until the rsync server is fixed, you can update MacPorts by downloading the appropriate OS-X-version-specific installer from the MacPorts web site. This will not erase your installed ports.
I did not see one, but if you see an error message at the end of the installer when it tries to contact the rsync server, you can ignore it; MacPorts should still have been successfully updated, which you can verify by typing "port version".
Tried this but it didn't fix the problem. Still getting error Error: /opt/local/bin/port: port selfupdate failed: Failed to verify signature for MacPorts source!
comment:152 Changed 9 years ago by marco.outatime@…
Hi, I just want to notify that at the moment I'm unable to use Macports at all. I've just installed it from scratch on El Capitan. The "port search" is broken and requires "port selfupdate", which cannot be done because of the signature failure reported in this thread. If you know a workaround let me know. Thanks.
comment:154 follow-up: 159 Changed 9 years ago by ryandesign (Ryan Carsten Schmidt)
"port search" doesn't require "port selfupdate"; it does require a portindex, which is created either by running "sudo port selfupdate" (which you can't right now because the rsync server is broken) or by running "sudo port sync" (which you can do if you change you MacPorts to sync with svn instead of rsync).
comment:155 Changed 9 years ago by marco.outatime@…
port search XXX Warning: Can't open index file for source: rsync://rsync.macports.org/release/tarballs/ports.tar Error: search for name XXX failed: No index(es) found! Have you synced your port definitions? Try running 'port selfupdate'. No match for XXX found
Ah. So please let us know when you find a workaround for both the rsync and the signature failure. For the rsync server do you have an ETA? Thank you.
comment:156 Changed 9 years ago by ryandesign (Ryan Carsten Schmidt)
The workaround for sync failure is in comment:27. The workaround for selfupdate failure is in comment:3.
comment:159 follow-up: 161 Changed 9 years ago by atma@…
Replying to ryandesign@…:
"port search" doesn't require "port selfupdate"; it does require a portindex, which is created either by running "sudo port selfupdate" (which you can't right now because the rsync server is broken) or by running "sudo port sync" (which you can do if you change you MacPorts to sync with svn instead of rsync).
MacPorts worked fine for me. I installed them today via "El Capitan" pkg on the frontpage. Then synced the pkg-list running "sudo port sync". It took some time to download the entire tree. Then I proceed installing 'vim' and 'postgresql' normally.
comment:161 Changed 9 years ago by p.fabrizio.salvatore@…
Replying to atma@…:
Replying to ryandesign@…:
"port search" doesn't require "port selfupdate"; it does require a portindex, which is created either by running "sudo port selfupdate" (which you can't right now because the rsync server is broken) or by running "sudo port sync" (which you can do if you change you MacPorts to sync with svn instead of rsync).
MacPorts worked fine for me. I installed them today via "El Capitan" pkg on the frontpage. Then synced the pkg-list running "sudo port sync". It took some time to download the entire tree. Then I proceed installing 'vim' and 'postgresql' normally.
I run the same command and it does indeed work for me too. Just to clarify, you don't 'need' to install vim and postgresql, it is just that you do need them, right?
Thanks!
Fab
comment:162 Changed 9 years ago by meckiemac@…
As long I don't get an official answer why the key changed I wouldn't trust this server anymore. In my view this is a security breach and I stop upgrading until a real solution. Who is the owner of the server?
comment:163 Changed 9 years ago by joaogeada (Joao Geada)
I agree 100% with meckiemac.
Right now I am assuming the macports server has been compromised and will not trust anything served from there until I hear a satisfactory official answer.
comment:164 Changed 9 years ago by alessandropaggi (alessandro)
Cc: | alessandro.paggi@… removed |
---|
Cc Me!
comment:165 Changed 9 years ago by macports@…
Could we perhaps get some "official" statement/info, and a recommend safe workaround (if there is one) or something like that put on the MacPorts website? e.g. the ProblemHotlist? or even higher up (download/front page of macports project)
I suspect this would qualify as at least worthy of the Hotlist given its a couple of days old, with ~13 duplicates, ~160 comments and is a show-stopper for some (at least without a workaround).
comment:166 follow-up: 168 Changed 9 years ago by ryandesign (Ryan Carsten Schmidt)
The server was not compromised, but the disk was corrupted. The administrator has repaired the corruption. In a few hours I will check to see if the files are now ok.
comment:168 follow-up: 169 Changed 9 years ago by jackh48@…
Replying to ryandesign@…:
The server was not compromised, but the disk was corrupted. The administrator has repaired the corruption. In a few hours I will check to see if the files are now ok.
Works for me!
comment:169 Changed 9 years ago by pmo@…
Back in business. All OK. Thanks for the maintenance work. Cheers.
comment:170 follow-up: 173 Changed 9 years ago by macuserguru
It works now but one rsync error comes
$ sudo port -v selfupdate ....... sent 64 bytes received 636 bytes 280.00 bytes/sec total size is 512 speedup is 0.73 receiving file list ... rsync: change_dir "tarballs/PortIndex_darwin_15_i386" (in release) failed: No such file or directory (2) done sent 4 bytes received 9 bytes 8.67 bytes/sec total size is 0 speedup is 0.00 rsync error: some files could not be transferred (code 23) at /BuildRoot/Library/Caches/com.apple.xbs/Sources/rsync/rsync-47/rsync/main.c(1400) [receiver=2.6.9] Command failed: /usr/bin/rsync -rtzv --delete-after rsync://rsync.macports.org/release/tarballs/PortIndex_darwin_15_i386/PortIndex /opt/local/var/macports/sources/rsync.macports.org/release/tarballs Exit code: 23 Creating port index in /opt/local/var/macports/sources/rsync.macports.org/release/tarballs/ports Adding port aqua/Quicksilver Adding port aqua/TeXShop3 ....... Adding subport xtide-data Total number of ports parsed: 543 Ports successfully parsed: 543 Ports failed: 0 Up-to-date ports skipped: 24332 ---> MacPorts base is already the latest version The ports tree has been updated. To upgrade your installed ports, you should run port upgrade outdated
comment:173 Changed 9 years ago by ryandesign (Ryan Carsten Schmidt)
comment:176 follow-up: 177 Changed 9 years ago by macuserguru
those are now:
$ sudo port -v selfupdate ...... sent 64 bytes received 636 bytes 280.00 bytes/sec total size is 512 speedup is 0.73 receiving file list ... rsync: change_dir "tarballs/PortIndex_darwin_15_i386" (in release) failed: No such file or directory (2) done sent 4 bytes received 9 bytes 8.67 bytes/sec total size is 0 speedup is 0.00 rsync error: some files could not be transferred (code 23) at /BuildRoot/Library/Caches/com.apple.xbs/Sources/rsync/rsync-47/rsync/main.c(1400) [receiver=2.6.9] Command failed: /usr/bin/rsync -rtzv --delete-after rsync://rsync.macports.org/release/tarballs/PortIndex_darwin_15_i386/PortIndex /opt/local/var/macports/sources/rsync.macports.org/release/tarballs Exit code: 23 Creating port index in /opt/local/var/macports/sources/rsync.macports.org/release/tarballs/ports Adding port aqua/emacs-mac-app Adding port aqua/terminal-notifier
$ port clean --all installed ---> Cleaning aspell Warning: Only cleaning in ~/.macports; insufficient privileges for standard locations ---> Cleaning aspell-dict-de Warning: Only cleaning in ~/.macports; insufficient privileges for standard locations ---> Cleaning aspell-dict-en Warning: Only cleaning in ~/.macports; insufficient privileges for standard locations ---> Cleaning atk Warning: Only cleaning in ~/.macports; insufficient privileges for standard locations ---> Cleaning autoconf Warning: Only cleaning in ~/.macports; insufficient privileges for standard locations
comment:177 Changed 9 years ago by ryandesign (Ryan Carsten Schmidt)
Resolution: | → fixed |
---|---|
Status: | new → closed |
This problem repros for me using OS X 10.11 and the latest stable "MacPorts-2.3.4-10.11".
Here's all I see happening "under the hood" with the verification step -- nothing very exciting --
Here's what the files look like: