comparison lisp/w3/ssl.el @ 118:7d55a9ba150c r20-1b11

Import from CVS: tag r20-1b11
author cvs
date Mon, 13 Aug 2007 09:24:17 +0200
parents 8d2a9b52c682
children
comparison
equal deleted inserted replaced
117:578fd4947a72 118:7d55a9ba150c
1 ;;; ssl.el,v --- ssl functions for emacsen without them builtin 1 ;;; ssl.el,v --- ssl functions for emacsen without them builtin
2 ;; Author: wmperry 2 ;; Author: wmperry
3 ;; Created: 1997/03/26 00:04:40 3 ;; Created: 1997/03/31 16:22:42
4 ;; Version: 1.13 4 ;; Version: 1.14
5 ;; Keywords: comm 5 ;; Keywords: comm
6 6
7 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; 7 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
8 ;;; Copyright (c) 1995, 1996 by William M. Perry (wmperry@cs.indiana.edu) 8 ;;; Copyright (c) 1995, 1996 by William M. Perry (wmperry@cs.indiana.edu)
9 ;;; Copyright (c) 1996, 1997 Free Software Foundation, Inc. 9 ;;; Copyright (c) 1996, 1997 Free Software Foundation, Inc.
41 (defmacro defcustom (var value doc &rest args) 41 (defmacro defcustom (var value doc &rest args)
42 (` (defvar (, var) (, value) (, doc)))))) 42 (` (defvar (, var) (, value) (, doc))))))
43 43
44 (defgroup ssl nil 44 (defgroup ssl nil
45 "Support for `Secure Sockets Layer' encryption." 45 "Support for `Secure Sockets Layer' encryption."
46 :group 'emacs) 46 :group 'comm)
47 47
48 (defcustom ssl-certificate-directory "~/.w3/certs/" 48 (defcustom ssl-certificate-directory "~/.w3/certs/"
49 "*Directory to store CA certificates in" 49 "*Directory to store CA certificates in"
50 :group 'ssl 50 :group 'ssl
51 :type 'directory) 51 :type 'directory)
72 "*Style of cert database to use, the only valid value right now is `ssleay'. 72 "*Style of cert database to use, the only valid value right now is `ssleay'.
73 This means a directory of pem encoded certificates with hash symlinks." 73 This means a directory of pem encoded certificates with hash symlinks."
74 :group 'ssl 74 :group 'ssl
75 :type '(choice (const :tag "SSLeay" :value ssleay))) 75 :type '(choice (const :tag "SSLeay" :value ssleay)))
76 76
77 (defcustom ssl-certificate-verification-depth 0 77 (defcustom ssl-certificate-verification-policy 0
78 "*How far up the certificate chain we should verify." 78 "*How far up the certificate chain we should verify."
79 :group 'ssl 79 :group 'ssl
80 :type 'integer) 80 :type '(choice (const :tag "No verification" :value 0)
81 (const :tag "Verification required" :value 1)
82 (const :tag "Reject connection if verification fails" :value 3)
83 (const :tag "SSL_VERIFY_CLIENT_ONCE" :value 5)))
81 84
82 (defcustom ssl-program-name "s_client" 85 (defcustom ssl-program-name "s_client"
83 "*The program to run in a subprocess to open an SSL connection." 86 "*The program to run in a subprocess to open an SSL connection."
84 :group 'ssl 87 :group 'ssl
85 :type 'string) 88 :type 'string)
86 89
87 (defcustom ssl-program-arguments 90 (defcustom ssl-program-arguments
88 '(;;"-quiet" 91 '(;;"-quiet"
89 "-host" host 92 "-host" host
90 "-port" service 93 "-port" service
91 "-verify" (int-to-string ssl-certificate-verification-depth) 94 "-verify" (int-to-string ssl-certificate-verification-policy)
92 "-CApath" ssl-certificate-directory 95 "-CApath" ssl-certificate-directory
93 ) 96 )
94 "*Arguments that should be passed to the program `ssl-program-name'. 97 "*Arguments that should be passed to the program `ssl-program-name'.
95 This should be used if your SSL program needs command line switches to 98 This should be used if your SSL program needs command line switches to
96 specify any behaviour (certificate file locations, etc). 99 specify any behaviour (certificate file locations, etc).