Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

Is there an command line option to auto accept a SSL certificate permanently using the SVN commandline in a way that avoids the prompt?

share|improve this question
    
Would this be a better fit at Stack Overflow? –  James McMahon Jul 8 '09 at 20:46

3 Answers 3

up vote 13 down vote accepted

It depends somewhat on your version of svn. Recent (1.6+) ones have the usual --non-interactive (which you want to use to avoid prompts) and also a --trust-server-cert that may do what you want.

share|improve this answer
    
This solution seems to work. Unfortunately the command line certificate accept didn't solve my initial problem. Oh well, at least I know what doesn't work now. –  James McMahon Jul 9 '09 at 15:19
    
If this still doesn't work, it may be because you can't access/create the .subversion directory in your home directory. Solution found here: chipsandtv.com/articles/svn-invalid-certificates –  icc97 Apr 26 '12 at 16:40
    
The chipsandtv.com link is dead. Is there another source? –  Joe McMahon Jan 17 '13 at 1:01
    

Using --trust-server-cert will not permanently accept the SSL certificate. You can permanently accept the SSL certificate via the command line using Input Redirection and not using --non-interactive.

Here's an example for Unix/Linux:

svn list [TARGET] << EOF
p
EOF

NOTE: The "p" above is for (p)ermanently.

share|improve this answer

You should be able to download the certificate and then place it in the appropriate directory. Or you can download the CA certificate and then set the configuration option ssl-authority-files to trust that CA.

See the SSL Certificate Management section in the book.

share|improve this answer
    
I'm in a very strange situation here, see serverfault.com/questions/7648/…, so I want to be able to pull it off in one command. –  James McMahon Jul 8 '09 at 21:07

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.