1
0

easy-rsa.patch 8.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218
  1. diff -Nur openvpn-2.0.8_orig/easy-rsa/2.0/build-ca openvpn-2.0.8/easy-rsa/2.0/build-ca
  2. --- openvpn-2.0.8_orig/easy-rsa/2.0/build-ca 2005-11-02 19:42:38.000000000 +0100
  3. +++ openvpn-2.0.8/easy-rsa/2.0/build-ca 2006-10-13 18:14:32.000000000 +0200
  4. @@ -1,8 +1,7 @@
  5. -#!/bin/bash
  6. +#!/bin/sh
  7. #
  8. # Build a root certificate
  9. #
  10. -export EASY_RSA="${EASY_RSA:-.}"
  11. -"$EASY_RSA/pkitool" --interact --initca $*
  12. +/usr/sbin/pkitool --interact --initca $*
  13. diff -Nur openvpn-2.0.8_orig/easy-rsa/2.0/build-dh openvpn-2.0.8/easy-rsa/2.0/build-dh
  14. --- openvpn-2.0.8_orig/easy-rsa/2.0/build-dh 2006-06-28 08:29:27.000000000 +0200
  15. +++ openvpn-2.0.8/easy-rsa/2.0/build-dh 2006-10-13 18:13:40.000000000 +0200
  16. @@ -1,4 +1,6 @@
  17. -#!/bin/bash
  18. +#!/bin/sh
  19. +
  20. +. /etc/easy-rsa/vars
  21. # Build Diffie-Hellman parameters for the server side
  22. # of an SSL/TLS connection.
  23. diff -Nur openvpn-2.0.8_orig/easy-rsa/2.0/build-inter openvpn-2.0.8/easy-rsa/2.0/build-inter
  24. --- openvpn-2.0.8_orig/easy-rsa/2.0/build-inter 2005-11-02 19:42:39.000000000 +0100
  25. +++ openvpn-2.0.8/easy-rsa/2.0/build-inter 2006-10-13 18:14:32.000000000 +0200
  26. @@ -1,7 +1,6 @@
  27. -#!/bin/bash
  28. +#!/bin/sh
  29. # Make an intermediate CA certificate/private key pair using a locally generated
  30. # root certificate.
  31. -export EASY_RSA="${EASY_RSA:-.}"
  32. -"$EASY_RSA/pkitool" --interact --inter $*
  33. +/usr/sbin/pkitool --interact --inter $*
  34. diff -Nur openvpn-2.0.8_orig/easy-rsa/2.0/build-key openvpn-2.0.8/easy-rsa/2.0/build-key
  35. --- openvpn-2.0.8_orig/easy-rsa/2.0/build-key 2005-11-02 19:42:39.000000000 +0100
  36. +++ openvpn-2.0.8/easy-rsa/2.0/build-key 2006-10-13 18:14:32.000000000 +0200
  37. @@ -1,7 +1,6 @@
  38. -#!/bin/bash
  39. +#!/bin/sh
  40. # Make a certificate/private key pair using a locally generated
  41. # root certificate.
  42. -export EASY_RSA="${EASY_RSA:-.}"
  43. -"$EASY_RSA/pkitool" --interact $*
  44. +/usr/sbin/pkitool --interact $*
  45. diff -Nur openvpn-2.0.8_orig/easy-rsa/2.0/build-key-pass openvpn-2.0.8/easy-rsa/2.0/build-key-pass
  46. --- openvpn-2.0.8_orig/easy-rsa/2.0/build-key-pass 2005-11-02 19:42:39.000000000 +0100
  47. +++ openvpn-2.0.8/easy-rsa/2.0/build-key-pass 2006-10-13 18:14:32.000000000 +0200
  48. @@ -1,7 +1,6 @@
  49. -#!/bin/bash
  50. +#!/bin/sh
  51. # Similar to build-key, but protect the private key
  52. # with a password.
  53. -export EASY_RSA="${EASY_RSA:-.}"
  54. -"$EASY_RSA/pkitool" --interact --pass $*
  55. +/usr/sbin/pkitool --interact --pass $*
  56. diff -Nur openvpn-2.0.8_orig/easy-rsa/2.0/build-key-pkcs12 openvpn-2.0.8/easy-rsa/2.0/build-key-pkcs12
  57. --- openvpn-2.0.8_orig/easy-rsa/2.0/build-key-pkcs12 2005-11-02 19:42:39.000000000 +0100
  58. +++ openvpn-2.0.8/easy-rsa/2.0/build-key-pkcs12 2006-10-13 18:14:32.000000000 +0200
  59. @@ -1,8 +1,7 @@
  60. -#!/bin/bash
  61. +#!/bin/sh
  62. # Make a certificate/private key pair using a locally generated
  63. # root certificate and convert it to a PKCS #12 file including the
  64. # the CA certificate as well.
  65. -export EASY_RSA="${EASY_RSA:-.}"
  66. -"$EASY_RSA/pkitool" --interact --pkcs12 $*
  67. +/usr/sbin/pkitool --interact --pkcs12 $*
  68. diff -Nur openvpn-2.0.8_orig/easy-rsa/2.0/build-key-server openvpn-2.0.8/easy-rsa/2.0/build-key-server
  69. --- openvpn-2.0.8_orig/easy-rsa/2.0/build-key-server 2005-11-02 19:42:39.000000000 +0100
  70. +++ openvpn-2.0.8/easy-rsa/2.0/build-key-server 2006-10-13 18:14:32.000000000 +0200
  71. @@ -1,4 +1,4 @@
  72. -#!/bin/bash
  73. +#!/bin/sh
  74. # Make a certificate/private key pair using a locally generated
  75. # root certificate.
  76. @@ -6,5 +6,4 @@
  77. # Explicitly set nsCertType to server using the "server"
  78. # extension in the openssl.cnf file.
  79. -export EASY_RSA="${EASY_RSA:-.}"
  80. -"$EASY_RSA/pkitool" --interact --server $*
  81. +/usr/sbin/pkitool --interact --server $*
  82. diff -Nur openvpn-2.0.8_orig/easy-rsa/2.0/build-req openvpn-2.0.8/easy-rsa/2.0/build-req
  83. --- openvpn-2.0.8_orig/easy-rsa/2.0/build-req 2005-11-02 19:42:38.000000000 +0100
  84. +++ openvpn-2.0.8/easy-rsa/2.0/build-req 2006-10-13 18:14:32.000000000 +0200
  85. @@ -1,7 +1,6 @@
  86. -#!/bin/bash
  87. +#!/bin/sh
  88. # Build a certificate signing request and private key. Use this
  89. # when your root certificate and key is not available locally.
  90. -export EASY_RSA="${EASY_RSA:-.}"
  91. -"$EASY_RSA/pkitool" --interact --csr $*
  92. +/usr/sbin/pkitool --interact --csr $*
  93. diff -Nur openvpn-2.0.8_orig/easy-rsa/2.0/build-req-pass openvpn-2.0.8/easy-rsa/2.0/build-req-pass
  94. --- openvpn-2.0.8_orig/easy-rsa/2.0/build-req-pass 2005-11-02 19:42:39.000000000 +0100
  95. +++ openvpn-2.0.8/easy-rsa/2.0/build-req-pass 2006-10-13 18:14:32.000000000 +0200
  96. @@ -1,7 +1,6 @@
  97. -#!/bin/bash
  98. +#!/bin/sh
  99. # Like build-req, but protect your private key
  100. # with a password.
  101. -export EASY_RSA="${EASY_RSA:-.}"
  102. -"$EASY_RSA/pkitool" --interact --csr --pass $*
  103. +/usr/sbin/pkitool --interact --csr --pass $*
  104. diff -Nur openvpn-2.0.8_orig/easy-rsa/2.0/clean-all openvpn-2.0.8/easy-rsa/2.0/clean-all
  105. --- openvpn-2.0.8_orig/easy-rsa/2.0/clean-all 2005-11-02 19:42:39.000000000 +0100
  106. +++ openvpn-2.0.8/easy-rsa/2.0/clean-all 2006-10-13 18:13:40.000000000 +0200
  107. @@ -1,4 +1,6 @@
  108. -#!/bin/bash
  109. +#!/bin/sh
  110. +
  111. +. /etc/easy-rsa/vars
  112. # Initialize the $KEY_DIR directory.
  113. # Note that this script does a
  114. diff -Nur openvpn-2.0.8_orig/easy-rsa/2.0/inherit-inter openvpn-2.0.8/easy-rsa/2.0/inherit-inter
  115. --- openvpn-2.0.8_orig/easy-rsa/2.0/inherit-inter 2005-11-02 19:42:38.000000000 +0100
  116. +++ openvpn-2.0.8/easy-rsa/2.0/inherit-inter 2006-10-13 18:13:40.000000000 +0200
  117. @@ -1,4 +1,6 @@
  118. -#!/bin/bash
  119. +#!/bin/sh
  120. +
  121. +. /etc/easy-rsa/vars
  122. # Build a new PKI which is rooted on an intermediate certificate generated
  123. # by ./build-inter or ./pkitool --inter from a parent PKI. The new PKI should
  124. diff -Nur openvpn-2.0.8_orig/easy-rsa/2.0/list-crl openvpn-2.0.8/easy-rsa/2.0/list-crl
  125. --- openvpn-2.0.8_orig/easy-rsa/2.0/list-crl 2006-06-28 08:29:27.000000000 +0200
  126. +++ openvpn-2.0.8/easy-rsa/2.0/list-crl 2006-10-13 18:13:40.000000000 +0200
  127. @@ -1,4 +1,6 @@
  128. -#!/bin/bash
  129. +#!/bin/sh
  130. +
  131. +. /etc/easy-rsa/vars
  132. # list revoked certificates
  133. diff -Nur openvpn-2.0.8_orig/easy-rsa/2.0/pkitool openvpn-2.0.8/easy-rsa/2.0/pkitool
  134. --- openvpn-2.0.8_orig/easy-rsa/2.0/pkitool 2006-06-28 08:29:27.000000000 +0200
  135. +++ openvpn-2.0.8/easy-rsa/2.0/pkitool 2006-10-13 18:13:40.000000000 +0200
  136. @@ -1,5 +1,7 @@
  137. #!/bin/sh
  138. +. /etc/easy-rsa/vars
  139. +
  140. # OpenVPN -- An application to securely tunnel IP networks
  141. # over a single TCP/UDP port, with support for SSL/TLS-based
  142. # session authentication and key exchange,
  143. diff -Nur openvpn-2.0.8_orig/easy-rsa/2.0/revoke-full openvpn-2.0.8/easy-rsa/2.0/revoke-full
  144. --- openvpn-2.0.8_orig/easy-rsa/2.0/revoke-full 2006-06-28 08:29:27.000000000 +0200
  145. +++ openvpn-2.0.8/easy-rsa/2.0/revoke-full 2006-10-13 18:13:40.000000000 +0200
  146. @@ -1,4 +1,6 @@
  147. -#!/bin/bash
  148. +#!/bin/sh
  149. +
  150. +. /etc/easy-rsa/vars
  151. # revoke a certificate, regenerate CRL,
  152. # and verify revocation
  153. diff -Nur openvpn-2.0.8_orig/easy-rsa/2.0/sign-req openvpn-2.0.8/easy-rsa/2.0/sign-req
  154. --- openvpn-2.0.8_orig/easy-rsa/2.0/sign-req 2005-11-02 19:42:39.000000000 +0100
  155. +++ openvpn-2.0.8/easy-rsa/2.0/sign-req 2006-10-13 18:14:32.000000000 +0200
  156. @@ -1,7 +1,6 @@
  157. -#!/bin/bash
  158. +#!/bin/sh
  159. # Sign a certificate signing request (a .csr file)
  160. # with a local root certificate and key.
  161. -export EASY_RSA="${EASY_RSA:-.}"
  162. -"$EASY_RSA/pkitool" --interact --sign $*
  163. +/usr/sbin/pkitool --interact --sign $*
  164. diff -Nur openvpn-2.0.8_orig/easy-rsa/2.0/vars openvpn-2.0.8/easy-rsa/2.0/vars
  165. --- openvpn-2.0.8_orig/easy-rsa/2.0/vars 2006-06-28 08:29:27.000000000 +0200
  166. +++ openvpn-2.0.8/easy-rsa/2.0/vars 2006-10-13 18:24:03.000000000 +0200
  167. @@ -12,7 +12,7 @@
  168. # This variable should point to
  169. # the top level of the easy-rsa
  170. # tree.
  171. -export EASY_RSA="`pwd`"
  172. +export EASY_RSA="/etc/easy-rsa"
  173. #
  174. # This variable should point to
  175. @@ -26,7 +26,7 @@
  176. # This variable should point to
  177. # the openssl.cnf file included
  178. # with easy-rsa.
  179. -export KEY_CONFIG=`$EASY_RSA/whichopensslcnf $EASY_RSA`
  180. +export KEY_CONFIG=`/usr/sbin/whichopensslcnf $EASY_RSA`
  181. # Edit this variable to point to
  182. # your soon-to-be-created key
  183. @@ -39,7 +39,7 @@
  184. export KEY_DIR="$EASY_RSA/keys"
  185. # Issue rm -rf warning
  186. -echo NOTE: If you run ./clean-all, I will be doing a rm -rf on $KEY_DIR
  187. +echo NOTE: If you run /usr/sbin/clean-all, I will be doing a rm -rf on $KEY_DIR
  188. # Increase this to 2048 if you
  189. # are paranoid. This will slow