In my case, I followed the following instructions to fix the issue on macOS Sequoia:
1- Delete any certs that currently exist. Open a terminal and run: dotnet dev-certs https --clean
2- Download the tar.gz file of the "main" release from the .NET SDK package table.
3- Unpack the downloaded file.
4- Remove the quarantine attribute from the unpacked folder. From your terminal run: xattr -d com.apple.quarantine -r Replace with the name of your unpacked folder.
5- Navigate to the unpacked folder
6- From within this folder, run the following to generate and trust the certificate. ./dotnet dev-certs https --trust