I got this message while trying to do update my DietPi the other day. Here is what I did to be able to update which then updates the certificate with the issue:
nano /etc/apt/sources.list
replace https with http
save and exit the file
apt update
apt upgrade
nano /etc/apt/sources.list
replace http with https
save and exit the file
dietpi-update
Be sure to change the URL’s in the file sources.list back to HTTPS in order to have encryption again when updating. If you don’t you could be opening yourself up to man in the middle attacks, etc.