Skip to content

[HowTo] Verify signatures #2

@xiota

Description

@xiota

Import good keys:

locate chaotic-trusted

for i in $(locate chaotic-trusted) ; do
  sha256sum "$i"
done

for i in $(cut -d: -f1 $(locate chaotic-trusted | head -1)) ; do
  gpg  --keyserver keyserver.ubuntu.com --recv-key "$i"
done

Remove bad keys:

locate chaotic-revoked

for i in $(locate chaotic-revoked) ; do
  sha256sum "$i"
done

for i in $(cut -d: -f1 $(locate chaotic-revoked | head -1)) ; do
  gpg --delete-keys --fingerprint "$i"
done

Find packages with missing signatures:

cd /srv/http/repos/chaotic-aur/x86_64

for i in *.pkg.tar.{zst,gz,xz} ; do
  [ -e "$i" ] && if [ -e "$i.sig" ] ; then
    :
  else
    
    echo "Missing: $i" | sed -E 's&-([^-]+-[0-9\.]+)-(x86_64|any)\.pkg\.tar\..*$& \1&'
  fi
done

Verify signed packages:

cd /srv/http/repos/chaotic-aur/x86_64

for i in *.sig ; do
  if gpg --verify "$i" 2> /dev/null ; then
    :
  else
    echo "Failed: $i" | sed -E 's&-([^-]+-[0-9\.]+)-(x86_64|any)\.pkg\.tar\..*$& \1&'
  fi
done

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions