Regular web app getting a 500 code on callback

This is my login link:

A style="font-family: Montserrat,Arial,Helvetica; font-size: 14pt; text-decoration: none;" href="https://MyName.us.auth0.com/authorize?response_type=code&client_id=MyId&redirect_uri=https://MyServer/bin/smauth0.cgi&scope=openid%20profile%20email&state=LSICallback">LOGIN</A>

my apache log shows error code 500 instead of 302 redirect.

192.168.1.1 - - [14/Jul/2021:08:47:35 -0400] "GET /~silentm/bin/smauth0.cgi?code=W7PWqlVty0PeR_sW&state=LSICallback HTTP/1.1" 500 527

I am using regular web app, apache setup. I have this in my auth_openidc.conf

IDCProviderMetadataURL https://MyName.us.auth0.com/.well-known/openid-configuration
OIDCClientID MyId 
OIDCClientSecret MySecret

OIDCScope "openid name email"
OIDCRedirectURI https://MyServer.com/bin/smauth0.cgi
OIDCCryptoPassphrase MyPW

<Location /bin>
   AuthType openid-connect
   Require valid-user
   LogLevel debug
</Location>

I have no idea why?
Thanks

Jerry

This was actually an issue in my callback script. Sorry,

Jerry