"Error Code: 500 Internal Server Error"

CAC access to secure web sites for Mac OS
carl
Site Admin
Posts: 178
Joined: Wed Feb 23, 2011 5:04 pm
Location: Arlington, Texas
Contact:

Re: "Error Code: 500 Internal Server Error"

Post by carl » Wed Feb 22, 2017 6:04 pm

One thing that I always try is a different browser. Both Google Chrome and Apple's Safari use the Keychain, so either should work. If you can't get one to work, try the other -- even if it's just to see if a different error message might help explain the problem more.

Nathan, can you confirm that you're getting a PIN prompt when accessing Navy west webmail? Or does the error appear before the PIN dialog?

Nathan
Posts: 8
Joined: Wed Feb 22, 2017 11:56 am

Re: "Error Code: 500 Internal Server Error"

Post by Nathan » Wed Feb 22, 2017 6:18 pm

OK, I cleared out the .mil cookie as suggested and restarted the mac. Same 500 error. Also go the 500 error with the Navy East webmail.

Nathan
Posts: 8
Joined: Wed Feb 22, 2017 11:56 am

Re: "Error Code: 500 Internal Server Error"

Post by Nathan » Wed Feb 22, 2017 11:23 pm

I've tried both Safari and Chrome. The error pops right away (no prompt to enter my CAC card PIN). The web page tries to load for maybe 2-3 seconds, and then the 500 error is displayed (both browsers). 2-3 weeks ago, everything was fine so I'm not sure what happened. This sort of thing would happen occasionally in the past, but would usually self-resolve after I waited a day and restarted the computer. Sometimes I would have to go into Keychain access and delete the Navy West Webmail identity preference. Now its been several weeks and multiple restarts with no luck. Its frustrating!

kim
Posts: 16
Joined: Fri Apr 29, 2016 10:22 am

Re: "Error Code: 500 Internal Server Error"

Post by kim » Thu Feb 23, 2017 12:09 am

Nathan wrote:I've tried both Safari and Chrome. The error pops right away (no prompt to enter my CAC card PIN). The web page tries to load for maybe 2-3 seconds, and then the 500 error is displayed (both browsers). 2-3 weeks ago, everything was fine so I'm not sure what happened. This sort of thing would happen occasionally in the past, but would usually self-resolve after I waited a day and restarted the computer. Sometimes I would have to go into Keychain access and delete the Navy West Webmail identity preference. Now its been several weeks and multiple restarts with no luck. Its frustrating!
Are you able to access any other sites requiring a CAC login like Navy Reserve Homeport? If you're presented with your cert list and a PIN prompt, we'll know PKard is working properly and the problem is due to something else interfering. Also, could there have possibly been any anti-virus/anti-malware software installed on your Mac since this worked the last time?

Nathan
Posts: 8
Joined: Wed Feb 22, 2017 11:56 am

Re: "Error Code: 500 Internal Server Error"

Post by Nathan » Fri Feb 24, 2017 2:10 pm

This is the strangest thing. So yes, I had installed Avast on my Mac. I disabled all of that, cleared out the cookies, cleared Safari history, deleted the webmail west identity preference in keychain access, and then restarted my computer. I opened up Safari and the PIN prompt appeared! So I entered my PIN...but then the PIN window just kept popping up over and over again. Tried all the available certificates in the PIN window too. That hangup happened occasionally in the past (and I'm still not sure what causes it - different subject). So I quit Safari and restarted it. Then the Navy webmail site wouldn't load (no 500 error, just wouldn't load = timeout). After again wiping history/keychain/cookie I uninstalled the entire program (including moving the .dmg file into the trash), and I restarted from scratch. Same thing. Did the whole process a second time. Tried the Navy West webmail site again - this time it took nearly 5 minutes to load, but didn't time out. Got the PIN prompt and it worked. So I'm back in!

I'm writing all of this just in case someone else has similar issues. At this point I will gladly rub my belly, pat my head and sing the nation anthem simultaneously if that's what it takes to get consistent access. I suspect either the Avast web shield or mail shield components caused the problem. But after turning those off, I'm at a loss for what caused all the pain thereafter.

I sincerely thank everyone who helped me solve this issue!

michaelwolfe
Posts: 319
Joined: Fri Feb 17, 2012 11:49 am

Re: "Error Code: 500 Internal Server Error"

Post by michaelwolfe » Fri Feb 24, 2017 2:35 pm

Nathan,

Yes, Avast's web shield is what had been preventing Safari from accessing your CAC in the Mac's Keychain. What I also find concerning is the multiple PIN prompts. If you tried any other CAC enabling application on your Mac, you may want to see if there are any reminents of the software. You can find the uninstall steps for the various enablers, including ours, on militarycac.com/macuninstall.htm. I recommend that you remove your card prior to deleting any of the other enablers, and then restarting your Mac. Another thing you may want to do is remove any token cache the other enablers would have created. Here are those steps:

- Remove your card from the reader
- Launch the Terminal from your Utilities folder
- Enter the following commands

sudo zsh
cd /var/db/TokenCache/tokens
rm -rf com.*

The sudo command will prompt you to enter your password like this:

Code: Select all

Michaels-iMac:~ michael$ sudo zsh
Password:
The password field will not display any dots, or characters, and will remain blank; just type your password and hit enter. The second command will change the directory following the path to "tokens". The last command deletes anything with "com." in the name within the tokens directory. For example:

Code: Select all

Michaels-iMac# ls -l
total 0
drwx--x--x  6 root  wheel  204 Feb 22 13:28 com.thursby.tokend.pkard:6176-6964-204D-6174-7465
drwx--x--x  6 root  wheel  204 Feb 15 17:00 com.thursby.tokend.pkard:6963-6861-656C-2057-6F6C
Please let us know if we can be of further assistance.


Michael

Nathan
Posts: 8
Joined: Wed Feb 22, 2017 11:56 am

Re: "Error Code: 500 Internal Server Error"

Post by Nathan » Fri Feb 24, 2017 3:25 pm

Thank you Michael. I've only had this mac since November, and this is the only CAC application I think I use - unless there any common ones I'm using but not aware of? I am just needing to access NMCI webmail. I tried the terminal commands as you instructed and I don't think I had any tokens. But it now says 0 found. Fortunately, I was again able to use my CAC and access the West webmail site like normal. Thank you again. This all has forced me to get a little too close to the Matrix for my comfort level/skills!

michaelwolfe
Posts: 319
Joined: Fri Feb 17, 2012 11:49 am

Re: "Error Code: 500 Internal Server Error"

Post by michaelwolfe » Fri Jun 02, 2017 7:43 am

Brentclark2003,

First, I recommend that you download and install PKard for Mac v1.7.1; you can find the download here.

Next I would like to better understand the issue you are having. What web site are you trying to log into? Are you prompted to select a certificate or enter your PIN number? What is the make and model of your CAC reader?


Michael

Post Reply