]> git.pld-linux.org Git - packages/certificates.git/commitdiff
- splits ca-bundle.crt from mod_ssl into separate certificates
authorTomasz Pala <gotar@pld-linux.org>
Mon, 20 Oct 2003 11:14:36 +0000 (11:14 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
Changed files:
    cert-split -> 1.1

cert-split [new file with mode: 0644]

diff --git a/cert-split b/cert-split
new file mode 100644 (file)
index 0000000..ad71079
--- /dev/null
@@ -0,0 +1,33 @@
+#!/usr/bin/perl -w
+
+use strict;
+
+my $buf="";
+my $crt="";
+my $in=0;
+
+while(<STDIN>) {
+       next if /^#/;
+       if(/^=+$/) {
+               if($in) {
+                       print CRT $crt;
+                       close CRT;
+                       $buf=~s|/|-|g;
+                       $buf=~s|\n||;
+                       open CRT,">$buf.crt";
+                       $buf="";
+                       $crt="";
+               } else {
+                       $buf=~s|/|-|g;
+                       $buf=~s|\n||;
+                       open CRT,">$buf.crt";
+                       $buf="";
+                       $in=1;
+               }
+       } else {
+               $crt.=$buf;
+               $buf=$_;
+       }
+}
+print CRT $crt.$buf;
+close CRT;
This page took 0.121437 seconds and 4 git commands to generate.