Crypt :: SmimeEngine.

Çϵå¿þ¾î ¿£ÁøÀÌ Áö¿øµÇ´Â SMIME ¸í·ÉÀ» OpenSSL¿¡ ´ëÇÑ Perl ÀÎÅÍÆäÀ̽º.
Áö±Ý ´Ù¿î·Îµå

Crypt :: SmimeEngine. ¼øÀ§ ¹× ¿ä¾à

±¤°í

  • Rating:
  • ƯÇã:
  • Perl Artistic License
  • °¡°Ý:
  • FREE
  • °Ô½ÃÀÚ À̸§:
  • Flavio Fanton
  • °Ô½ÃÀÚ À¥»çÀÌÆ®:
  • http://search.cpan.org/~flazan/

Crypt :: SmimeEngine. ű×


Crypt :: SmimeEngine. ¼³¸í

Çϵå¿þ¾î ¿£ÁøÀÌ Áö¿øµÇ´Â Smime ¸í·É¿¡ ´ëÇÑ OpenSSL¿¡ ´ëÇÑ Perl ÀÎÅÍÆäÀ̽º. Crypt :: SmimeEngineÀº Çϵå¿þ¾î ¿£Áø Áö¿øÀÌÀÖ´Â Smime ¸í·ÉÀ»À§ÇÑ OpenSSL¿¡ ´ëÇÑ Perl ÀÎÅÍÆäÀ̽ºÀÔ´Ï´Ù .Synopsis´Â Crypt :: SmimeEngine QW (INIT Sign GetFiving GetCertInfo Load_Privk GetErrstr ossl_version È®ÀÎ); $ cert_dir = 'certs /'; # °æ·Î ½Å·ÚÇÒ ¼öÀÖ´Â ÀÎÁõ¼­ $ cert = 'certs / cert.pem'; # °æ·Î ¼­¸íÀÚ ÀÎÁõ¼­ $ key = 'certs / key.pem'; # PATH °³ÀÎ Å° $ ORTER_CERT = []; # add # certs openssl ¿£Áø (HW ¿£Áø ¾øÀ½)À¸·Î ¸ðµâÀ» inzializeÇϵµ·ÏÇÏ°Ú½À´Ï´Ù. $ engine_type = 'OpenSSL'; $ OUT = init ($ cert_dir, $ cert, $ Å°, $ other_cert, $ engine_type); "ÇÁ·Î¼¼½º ÃʱâÈ­ :".geterrstr ()¿¡¼­ "ERRORE"DISE. " "$ out; Àμâ"init ok. "ÀÌÁ¦´Â Çϵå¿þ¾î ¿£ÁøÀ¸·Î ¸ðµâÀ» »èÁ¦ÇÒ ¼ö ÀÖ½À´Ï´Ù. # xxx remenber # xxxÀÌ ¸ðµâÀº NCipher Nethsm¿¡¼­¸¸ Àú¿¡°Ô Å×½ºÆ®¸¦ °ÅÃƽÀ´Ï´Ù !!! # XXX ´Ù¸¥ HW ¿£Áø $ engren_type = 'chil'À¸·Î ¼º°øÀûÀ¸·Î ½ÃµµÇÏ¸é ¾Ë·ÁÁֽʽÿÀ. $ engine_lib = '/ opt / nfast / toolkits / hwcrhk / libnfhwcrhk.so '; # xxx ¼³Ä¡½Ã °ËÁõ !!! $ OUT = init ($ cert_dir, $ cert, $ key, $ other_cert, $ engine_type, $ engry_lib); Á×À» " ÇÁ·Î¼¼½º¸¦ ÃʱâÈ­ÇϽʽÿÀ : "geterrstrstrstrstrstrstrstrstr ()". "$ out; Àμâ"init ok. "# ±âÈ£ $ mail_in = 'mail / mail.txt'; $ mail_out = 'mail / mail.txt.signed'; $ OUT = SIGN ($ mail_in, $ mail_out); $ outÀ» Àμâ ÇϽðڽÀ´Ï±î?"¿À·ù°¡ Ç¥½Ã : ". geterrstr (). " ":"±¦Âú¾Æ¿ä "# $ noverify = 1ÀÎÁö, # true ¾Æ´Ï¿À üÀÎÀ» °ËÁõÇÏ°í, ±×·¸Áö ¾ÊÀ¸¸é $ out = È®ÀÎ ($ mail_out, $ cert, $ noverify); $ out?"È®ÀÎ : ".geterrstrstr ()." ":"È®ÀÎÀ» È®ÀÎÇϽʽÿÀ »õ·Î¿î Å° ÀÎÁõ¼­ $ OUT = LOAD_PRIVK ($ NEW_KEY, $ NEW_CERT)·Îµå; $ OUTÀ» Àμâ ÇϽðڽÀ´Ï±î? "»õ Å° -CERT :".geterrstrstr () "¸¦·ÎµåÇÏ´Â Áß ¿À·ù°¡ ¹ß»ýÇß½À´Ï´Ù. ":"load_privk ok. "ÀÎÁõ¼­ Áö¹® $ schema = 'sha1'°¡Á® ¿À±â $ out = getFingerPrint ($ cert, $ schema); if (Á¤ÀÇ µÈ $ out) {print"Áö¹® ($ cert) : $ out "} else {print"{print "regrore Áö¹®À» ¾òÀ¸·Á¸é :"geterrstrstrstrstrstr (), " ";} # ÀÎÁõ¼­ Á¤º¸¸¦ ¾òÀ¸½Ê½Ã¿À $ obj = getCertInfo ($ cert); if (ref ($ obj)) {print"cert Á¤º¸ : "Àμâ"¹ßÇàÀÚ : ". $ obj -> { '¹ßÇàÀÚ'}," "Àμâ"Á¦¸ñ : ". $ obj -> { 'ÁÖÁ¦'}," "Àμâ"½Ã¸®¾ó : ". $ obj -> { 'serial'}," "; Àμâ"startDate : ". $ obj -> { 'startdate'}," "Àμâ"enddate : ". $ obj -> { 'enddate'}," "Àμâ"À̸ÞÀÏ : ". $ obj -> { 'v3_email'}," ";} else {print"getCertInfo : ".geterrstrstr ()," ";}ÀÌ ¸ðµâÀº Smime Á¶ÀÛÀ»À§ÇÑ OpenSSLÀÇ ±âº» ±â´ÉÀÌÀÖ´Â °£´ÜÇÑ ÀÎÅÍÆäÀ̽ºÀÔ´Ï´Ù. ȣȯ °¡´ÉÇÑ OpenSSL Çϵå¿þ¾î ¿£Áø¿¡¼­ ÀÛµ¿ ÇÒ ¼ö ÀÖ½À´Ï´Ù. À̶§ ¸ðµâÀº ¹ìµµ / ¼³¸í ±â´ÉÀ» ½ÇÇöÇÏÁö ¸øÇÕ´Ï´Ù. °ü½ÉÀÌÀÖ´Â °æ¿ì ÀúÀÚ¿¡°Ô ¾¹´Ï´Ù. ¿ä±¸ »çÇ× : ¡¤ Perl.


Crypt :: SmimeEngine. °ü·Ã ¼ÒÇÁÆ®¿þ¾î

Crypt :: Imail.

CRYPT :: IMAILÀº IMAIL ¾ÏÈ£¸¦ ¾ÏȣȭÇÏ°í Çص¶ÇÏ´Â µ¥ »ç¿ëÇÒ ¼öÀÖ´Â PERL ¸ðµâÀÔ´Ï´Ù. ...

189

´Ù¿î·Îµå