Create a self-signed public certificate to authenticate your application
Create a self-signed public certificate to authenticate your application in PowerShell
$certname = "My2024certificate"
$cert = New-SelfSignedCertificate -Subject "CN=$certname" -CertStoreLocation "Cert:\CurrentUser\My" -KeyExportPolicy Exportable -KeySpec Signature -KeyLength 2048 -KeyAlgorithm RSA -HashAlgorithm SHA256
Export-Certificate -Cert $cert -FilePath "$certname.cer" ## Specify your preferred location

Azure.RequestFailedException when start App in Visual Studio
Determine the first and last days of a quarter with Day.js
Login as another user in SharePoint 2019 on-premises site in Chrome