亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來(lái)到蟲(chóng)蟲(chóng)下載站! | ?? 資源下載 ?? 資源專(zhuān)輯 ?? 關(guān)于我們
? 蟲(chóng)蟲(chóng)下載站

?? ldap-utils.lib

?? Perl寫(xiě)的CA認(rèn)證程序
?? LIB
?? 第 1 頁(yè) / 共 2 頁(yè)
字號(hào):
#!/usr/bin/perl## RA Server Management Utility ## (c) 1999 by Massimiliano Pala## All Rights Reserved#### Project Information:#### 	Current Version ..................... $VER##      Project Started on .................. 17/12/1998##      Last Modified on .................... 30/03/2001##      Project Closed on ................... n/a#### Program currently tested with OpenLDAP v.1.2 on Linux, Solaris## and Sleepycat DB.#### DISC CLAIMER: THIS SOFTWARE IS GIVEN AS IS WITHOUT ANY WARRANTIES## ABOUT ANY DAMAGE DERIVED BY THE USE ( CORRECT OR NOT ) OF THIS## SOFTWARE. THE AUTHOR IS THEREFORE NOT RESPONSABLE IN ANY WAY OF## DAMAGES RELATED IN ANY WAY TO THIS OR SUPPORTED SOFTWARE AS WELL.#### If you want to contact me (the author) please use the e-mail## addresses listed below. Do not esitate in reporting bugs, enhancement## or anything seems useful in developing this software:####	madwolf@comune.modena.it##	m.pala@mo.nettuno.it##	digid@netscape.net#### Thank you for using this software, and remember that Open Projects## are the future of mankind. Do not sleep, partecipate to world wide## efforts to make life easier for all!sub addCertsUsers {  my @keys = @_;  ## Reserved Variables  my ( @certsList );  my ( $filename, $tmp, $ID, $cert, $ldap, $ret );  ## Get Required parameter  my $serverDir = getRequired( 'ServerDir' );  ## Debugging info  my $DEBUG = 0;  ## This file has the latest imported certificate's serials  $filename = "$serverDir/stuff/lastImport.txt";  ## Let's open the stuff/lastImport.txt  if( not -e "$filename" ) {    configError( "File $filename not found!");  }  $tmp = $query->getFile( "$filename");  if( $tmp eq "" ) {    success( "Last Import file was empty.");  }  my @certsList = split( "\n", $tmp );  my $table = $query->buildRefs ( ELEMENTS =>, MAXITEMS =>);  my $table .= $query->startTable (COLS=>[ "Cert.-No.",                                          "DN",                                          "adding dn",                                          "adding certificate" ],                              WIDTH=>"100%",                              TITLE_BGCOLOR=>"#DDCCFF");  foreach $ID (@certsList) {    my @line = ();    my ( $filter, $serID, $parsed, $ret, $entry );    ( $serID ) = ( $ID =~ /([a-f0-9]+)/i );    ## Let's be sure it is in the right format    $serID = uc( $serID );    $serID = "0$serID" if( length($serID) % 2 );    my $cert = $db->getItem ( DATATYPE => VALID_CERTIFICATE,                              KEY => $serID );    if( not $cert ) {      $table .= $query->addTableLine( DATA => [                    "<FONT COLOR=\"Red\">".                    "ERROR [$serID] : can't get certificate" .                    " from dB!\n</FONT>" ] );      next;    }    $parsed = $cert->getParsed();    push ( @line, $serID, $parsed->{DN});    $ret = addLDAPobject ( CERTIFICATE=>$cert );    my $text;    $text .= "<FONT COLOR=\"Red\">" if ( not $ret->{STATUS} );    $text .= $ret->{DESC};    $text .= "</FONT>" if ( not $ret->{STATUS} );    push ( @line, $text);    if( $ret->{STATUS} ) {      $ret = addLDAPattribute ( CERTIFICATE => $cert , NOPRINT => true);      if ($ret->{STATUS}) {        push (@line, "success");      } else {        push (@line, "Error : ".$ret->{CODE});      }    } else {      push (@line, "operation not performed");    }    $table .= $query->addTableLine ( DATA => [ @line ]);  }  $table .= $query->endTable;  print $table;  return "Ok.";}sub addLDAPobject {  ######################################################  ## only certs makes sense because a CRL can only be ##  ## produced if a valid CA-cert exists               ##  ######################################################  my $keys = { @_ };  local ( $obj, $parsed, $serID, $ldap, $ret, $dn, $cn, $sn, $email );  my $DEBUG = 0;  ## check the type of the attribute  $obj   = $keys->{CERTIFICATE};  return if ( not $obj );  ## get the needed data  my $cert_dn    = $obj->getParsed ()->{DN};  my $cert_cn    = $obj->getParsed ()->{CN};  my $cert_serID = $obj->getParsed ()->{SERIAL};  my $cert_email = $obj->getParsed ()->{EMAIL};  my $cert_ou    = $obj->getParsed ()->{OU};  my $cert_o     = $obj->getParsed ()->{O};  my $cert_l     = $obj->getParsed ()->{L};  my $cert_st    = $obj->getParsed ()->{ST};  ## debugging  print "Information of the Object:<br>\n" if ($DEBUG);  print "dn    ".$cert_dn."<br>\n" if ($DEBUG);  print "cn    ".$cert_cn."<br>\n" if ($DEBUG);  print "serID ".$cert_serID."<br>\n" if ($DEBUG);  print "email ".$cert_email."<br>\n" if ($DEBUG);  print "ou    ".$cert_ou."<br>\n" if ($DEBUG);  print "o     ".$cert_o."<br>\n" if ($DEBUG);  print "l     ".$cert_l."<br>\n" if ($DEBUG);  print "st    ".$cert_st."<br>\n" if ($DEBUG);  print "End of the information of the Object.<br>\n" if ($DEBUG);  ## here we could perform some operations with the data  ## sn is not the real sn sometimes but you can find  ## the person via a search with a wildcard  my $cert_sn = $cert_cn;  $cert_sn =~ s/^[^ ]* //;  my $ou_counter = 0;  my @ou_array   = ();  ## Get the Connection to the Server  if ( not ( $ldap = LDAP_connect() )) {    print "<FONT COLOR=\"Red\">";    print "LDAP [$serID]: Connection Refused by server!\n";    print "</FONT><BR>\n";    return;  };  ## Let's bind for a predetermined User  $ret = LDAP_bind( LDAP => $ldap );  if( not $ret->{STATUS} ) {    print "Failed in Bind: " . $ret->{CODE} . "\n";    LDAP_disconnect( LDAP => $ldap );    return $ret->{CODE};  };  ## build the array from the LDAP root  my $basedn = getRequired ('basedn');  my @basedn_array = ();  my $h_attribute;  while ($basedn) {    ## get the last element    $h_attribute = $basedn;    $basedn =~ s/^[^,]*,//;    $h_attribute = substr ($h_attribute,                            0,                            length ($h_attribute) - length ($basedn));    if ( not $h_attribute ) {      $h_attribute = $basedn;      $basedn = "";    }    $h_attribute =~ s/,//;    $h_attribute =~ s/(^ )|( $)//g;    print "element of baseDN: ".$h_attribute."<br>\n" if ($DEBUG);    if ($h_attribute =~ /^\s*ou\s*=.*$/i) {      $ou_array [$ou_counter] = $h_attribute;      $ou_array [$ou_counter] =~ s/^\s*ou\s*=\s*//i;      $ou_counter++;    }    push (@basedn_array, $h_attribute);  }  ## build the array from the DN  my $h_dn = $cert_dn;  my @dn_array = ();  my $h_attribute;  while ($h_dn) {    ## get the last element    $h_attribute = $h_dn;    $h_dn =~ s/^[^\/,]*\///;    $h_attribute = substr ($h_attribute,                            0,                            length ($h_attribute) - length ($h_dn));    if ( not $h_attribute ) {      $h_attribute = $h_dn;      $h_dn = "";    }    $h_attribute =~ s/\///;    $h_attribute =~ s/(^ )|( $)//g;    print "element of the inserted DN: ".$h_attribute."<br>\n" if ($DEBUG);    push (@dn_array, $h_attribute);  }  ## verify that the root in the DN is ok  print "Checking RootDN of Certificate ...<br>\n" if ($DEBUG);  print "Inserted DN\t\t\tBaseDN<br>\n" if ($DEBUG);  while (scalar (@basedn_array) and scalar (@dn_array)) {    my $h_basedn = pop (@basedn_array);    my $h_dn     = pop (@dn_array);    print $h_dn."\t\t".$h_basedn."<br>\n" if ($DEBUG);    ## this dn cannot be added under the root-dn    if ( (uc $h_basedn) ne (uc $h_dn) ) {      LDAP_disconnect ( $ldap );      return { STATUS => 0 ,                DESC => "Error ( dn conflicts with basedn )",               CODE => -1 };    }  }  ## dn which should be inserted is shorter then the root-dn  print "Checking the length of the DN of the Certificate ...<br>\n" if ($DEBUG);  if ( scalar (@basedn_array) ) {    LDAP_disconnect ( $ldap );    return { STATUS => 0 ,              DESC => "Error ( dn is shorter then basedn )",             CODE => -2 };  }  ## if dn == basedn then their is no error because this can   ## be the CA-dn  return { STATUS => 1, CODE => 0, DESC => "Success" }    if (!scalar (@dn_array));  ## setup the tree for the DN  ## attention only the last ldapadd must be successful !!!  print "Building the missing nodes of the LDAP-tree ...<br>\n" if ($DEBUG);  my $add_dn = getRequired ('basedn');  my $actual_element;  my $use_ldap_add = 0;  while (scalar (@dn_array)) {    $actual_element = pop @dn_array;    if ($actual_element =~ /^\s*ou\s*=.*$/i) {      $ou_array [$ou_counter] = $actual_element;      $ou_array [$ou_counter] =~ s/^\s*ou\s*=\s*//i;      $ou_counter++;    }    ## prepare the needed strings    $add_dn = $actual_element.",".$add_dn;    print "Try to add $add_dn ...<br>\n" if ($DEBUG);    ## check that the entry not exist in the LDAP-tree    my $base          = $add_dn;    #$base             =~ s/^[^,]*,//;    my $search_filter = $add_dn;    $search_filter    =~ s/,.*$//g;    $search_filter    =~ s/^email=/mail=/i;    $search_filter    = "(".$search_filter.")";    print "LDAP Searchfilter: ".$search_filter."<br>\n" if ($DEBUG);    print "LDAP Base: ".$base."<br>\n" if ($DEBUG);    my $ldap_search_mesg = $ldap->search (                             base => $base,                             scope => "sub",                             filter => $search_filter);    print "LDAP Search Mesg-Code ".$ldap_search_mesg->code."<br>\n" if ($DEBUG);    print "LDAP Search Mesg-Count ".$ldap_search_mesg->count."<br>\n" if ($DEBUG);    ## I stop the insertion because of a searcherror too    if ( not $ldap_search_mesg or          #$ldap_search_mesg->code or         $ldap_search_mesg->count) {      ## node/leaf exists      print "node exists<br>\n" if ($DEBUG);      next;    }    $use_ldap_add = 1;    ## insert the different types    ## attention: I don't insert here a CA!!!    ## this most be done otherwise because I cannot declare    ## any o and ou to be a (sub)CA    my @attr;    if ($add_dn =~ /^\s*(cn|email|serialNumber)\s*=.*$/i) {      return undef if (not $cert_sn or not $cert_cn);      push @attr, 'cn' => $cert_cn;      push @attr, 'sn' => $cert_sn;      push @attr, 'objectclass' => [ 'top',                                     'person',                                     'organizationalPerson',                                     'inetOrgPerson'                                    ];      push @attr, 'ou'   => [ @ou_array ] if (scalar @ou_array);      push @attr, 'o'    => $cert_o       if ($cert_o);      push @attr, 'mail' => $cert_email   if ($cert_email);      push @attr, 'st'   => $cert_st      if ($cert_st and $add_dn =~ /\s*st\s*=/i);

?? 快捷鍵說(shuō)明

復(fù)制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號(hào) Ctrl + =
減小字號(hào) Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
国产综合久久久久久鬼色| 9色porny自拍视频一区二区| 国产精品国产自产拍高清av | 国产精品日韩成人| 欧美精品在欧美一区二区少妇| 国产91精品一区二区| 天天综合网 天天综合色| 亚洲欧美自拍偷拍色图| 久久综合色之久久综合| 欧美日韩在线播放| 色综合视频一区二区三区高清| 国产一区不卡视频| 日产国产高清一区二区三区 | 韩国成人在线视频| 日本欧美肥老太交大片| 亚洲成a人片在线不卡一二三区| 国产精品视频九色porn| 久久欧美中文字幕| 日韩精品在线网站| 日韩欧美国产三级| 欧美另类videos死尸| 色八戒一区二区三区| 91视频免费播放| 99久免费精品视频在线观看 | 欧美一级日韩免费不卡| 欧美视频一区二区三区在线观看| 99re这里只有精品视频首页| 成人看片黄a免费看在线| 国产又粗又猛又爽又黄91精品| 七七婷婷婷婷精品国产| 午夜私人影院久久久久| 亚洲一区二区欧美| 亚洲成人手机在线| 午夜精品福利在线| 日韩精品亚洲专区| 日本最新不卡在线| 另类小说色综合网站| 精品一区二区三区不卡| 精品午夜一区二区三区在线观看| 日韩va亚洲va欧美va久久| 免费一级片91| 麻豆精品国产91久久久久久| 老司机精品视频在线| 国模套图日韩精品一区二区| 国内精品久久久久影院色| 国产精品1024| 不卡的av电影在线观看| 99免费精品视频| 欧美综合视频在线观看| 91精品在线观看入口| 欧美第一区第二区| 国产女主播视频一区二区| 国产精品亲子伦对白| 亚洲免费观看高清完整版在线观看 | 国产福利不卡视频| 大桥未久av一区二区三区中文| 成人黄色在线看| 欧洲亚洲精品在线| 欧美一区二区三区免费| 久久久久亚洲综合| 亚洲视频一二三区| 五月婷婷激情综合| 国产精品自产自拍| 91天堂素人约啪| 在线播放欧美女士性生活| 欧美精品一区二区三区视频| 国产精品久久久久久亚洲伦| 亚洲最大成人综合| 久久av老司机精品网站导航| 丰满少妇久久久久久久| 在线亚洲一区二区| 日韩欧美一二三| 国产精品美女久久久久aⅴ国产馆| 亚洲免费在线播放| 极品瑜伽女神91| voyeur盗摄精品| 宅男在线国产精品| 亚洲国产精品精华液ab| 偷拍自拍另类欧美| 国产aⅴ综合色| 欧美日韩和欧美的一区二区| 久久综合视频网| 亚洲第一综合色| 丰满少妇在线播放bd日韩电影| 欧美午夜精品久久久久久孕妇| 精品国产一区二区三区忘忧草| 亚洲丝袜另类动漫二区| 免费观看在线色综合| 色偷偷一区二区三区| 欧美xingq一区二区| 一区二区三区在线视频观看| 国内精品视频666| 欧美日韩色综合| 亚洲日本中文字幕区| 极品少妇xxxx偷拍精品少妇| 在线国产电影不卡| 中文字幕巨乱亚洲| 精品一二线国产| 欧美日韩一区三区四区| 国产精品成人在线观看| 国产伦精品一区二区三区免费 | 成人禁用看黄a在线| 欧美大片在线观看一区| 亚洲电影在线免费观看| 99久久er热在这里只有精品66| 精品国产污网站| 天堂精品中文字幕在线| 色8久久人人97超碰香蕉987| 中文字幕不卡三区| 国产剧情一区二区三区| 日韩一级黄色片| 亚洲亚洲精品在线观看| 色婷婷av一区| 亚洲欧美国产三级| 成人爱爱电影网址| 欧美极品另类videosde| 国产精品99久久久久| 欧美一级日韩不卡播放免费| 午夜久久福利影院| 欧美日韩免费电影| 一区二区免费看| 99精品久久免费看蜜臀剧情介绍| 欧美激情中文字幕| 国产精品亚洲а∨天堂免在线| 欧美电影免费观看高清完整版在线| 亚洲高清不卡在线| 欧美日韩精品一区二区三区| 亚洲成人激情自拍| 欧美日韩一区三区四区| 亚洲香蕉伊在人在线观| 欧美午夜精品免费| 亚洲成人一区在线| 欧美一区二区三区不卡| 日韩av中文字幕一区二区| 欧美一级在线免费| 久久福利资源站| 国产偷国产偷精品高清尤物| 成人午夜又粗又硬又大| 国产精品美女久久久久久久久久久| 福利一区二区在线| 亚洲四区在线观看| 在线一区二区观看| 婷婷中文字幕综合| 宅男在线国产精品| 国内精品久久久久影院色| 国产欧美日韩亚州综合| 成年人网站91| 国产精品福利av| 在线视频你懂得一区二区三区| 一区二区三区四区在线免费观看| 欧美性猛交xxxxxxxx| 亚洲第一成年网| 日韩一区二区三| 国产曰批免费观看久久久| 国产精品欧美久久久久无广告| 99久久久久久| 亚洲一区二区三区美女| 91精品国产一区二区三区| 精品一区二区三区免费毛片爱| 欧美激情中文字幕一区二区| 欧美一区二区日韩| 国产综合一区二区| 亚洲欧洲性图库| 欧美日本免费一区二区三区| 韩国女主播一区| 亚洲免费观看在线视频| 日韩欧美亚洲国产精品字幕久久久 | 久久欧美中文字幕| 91视视频在线观看入口直接观看www| 亚洲午夜精品一区二区三区他趣| 日韩欧美黄色影院| 99久久久无码国产精品| 天堂在线一区二区| 国产婷婷一区二区| 欧美日韩精品欧美日韩精品| 国产精品一卡二| 亚洲老妇xxxxxx| 久久这里只有精品首页| 欧美性生活一区| 国产揄拍国内精品对白| 亚洲午夜在线观看视频在线| 精品福利在线导航| 日本精品免费观看高清观看| 国产一区二区三区日韩| 亚洲成人在线观看视频| 欧美—级在线免费片| 日韩一区二区三区免费观看| 色综合久久中文综合久久97| 美女脱光内衣内裤视频久久网站 | 国产乱人伦精品一区二区在线观看| 亚洲欧洲av在线| 久久一日本道色综合| 欧美福利视频一区| 91在线视频播放| 国产精品综合网| 日韩精品欧美成人高清一区二区| 中文久久乱码一区二区| 日韩一二三四区| 欧美午夜视频网站| 91色视频在线|