1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 |
#!/bin/bash mypass='Password' # one password for each PFX file pfx=( 'domain1.pfx' 'domain2.pfx' 'domain3.pfx' ) for ((x = 0; x < ${#pfx[@]}; x++)) do echo "Exporting ${pfx[$x]}..." openssl pkcs12 -in ${pfx[$x]} -clcerts -nokeys -out ${pfx[$x]}.cer -passin pass:$mypass openssl pkcs12 -in ${pfx[$x]} -nocerts -nodes -out ${pfx[$x]}.enc.key -passin pass:$mypass openssl rsa -in ${pfx[$x]}.enc.key -out ${pfx[$x]}.key rm -f ${pfx[$x]}.enc.key echo "Done!" done |
Relativně dlouho jsem řešil, jak odstranit koncovku .php pomocí .htaccess souboru:
RewriteEngine On
RewriteBase /
#ze souboru settings.php neodstranovat koncovku php
RewriteCond %{REQUEST_URI} settings.php
RewriteRule settings.php settings.php [L]
#ze vsech ostatnich odstranit
RewriteCond %{REQUEST_URI} ^(.*)\.php$
RewriteRule ^(.*)\.php$ $1 [R,L]