apr::util.3

来自「视频监控网络部分的协议ddns,的模块的实现代码,请大家大胆指正.」· 3 代码 · 共 290 行

3
290
字号
.\" Automatically generated by Pod::Man 2.16 (Pod::Simple 3.05).\".\" Standard preamble:.\" ========================================================================.de Sh \" Subsection heading.br.if t .Sp.ne 5.PP\fB\\$1\fR.PP...de Sp \" Vertical space (when we can't use .PP).if t .sp .5v.if n .sp...de Vb \" Begin verbatim text.ft CW.nf.ne \\$1...de Ve \" End verbatim text.ft R.fi...\" Set up some character translations and predefined strings.  \*(-- will.\" give an unbreakable dash, \*(PI will give pi, \*(L" will give a left.\" double quote, and \*(R" will give a right double quote.  \*(C+ will.\" give a nicer C++.  Capital omega is used to do unbreakable dashes and.\" therefore won't be available.  \*(C` and \*(C' expand to `' in nroff,.\" nothing in troff, for use with C<>..tr \(*W-.ds C+ C\v'-.1v'\h'-1p'\s-2+\h'-1p'+\s0\v'.1v'\h'-1p'.ie n \{\.    ds -- \(*W-.    ds PI pi.    if (\n(.H=4u)&(1m=24u) .ds -- \(*W\h'-12u'\(*W\h'-12u'-\" diablo 10 pitch.    if (\n(.H=4u)&(1m=20u) .ds -- \(*W\h'-12u'\(*W\h'-8u'-\"  diablo 12 pitch.    ds L" "".    ds R" "".    ds C` "".    ds C' ""'br\}.el\{\.    ds -- \|\(em\|.    ds PI \(*p.    ds L" ``.    ds R" '''br\}.\".\" Escape single quotes in literal strings from groff's Unicode transform..ie \n(.g .ds Aq \(aq.el       .ds Aq '.\".\" If the F register is turned on, we'll generate index entries on stderr for.\" titles (.TH), headers (.SH), subsections (.Sh), items (.Ip), and index.\" entries marked with X<> in POD.  Of course, you'll have to process the.\" output yourself in some meaningful fashion..ie \nF \{\.    de IX.    tm Index:\\$1\t\\n%\t"\\$2"...    nr % 0.    rr F.\}.el \{\.    de IX...\}.\".\" Accent mark definitions (@(#)ms.acc 1.5 88/02/08 SMI; from UCB 4.2)..\" Fear.  Run.  Save yourself.  No user-serviceable parts..    \" fudge factors for nroff and troff.if n \{\.    ds #H 0.    ds #V .8m.    ds #F .3m.    ds #[ \f1.    ds #] \fP.\}.if t \{\.    ds #H ((1u-(\\\\n(.fu%2u))*.13m).    ds #V .6m.    ds #F 0.    ds #[ \&.    ds #] \&.\}.    \" simple accents for nroff and troff.if n \{\.    ds ' \&.    ds ` \&.    ds ^ \&.    ds , \&.    ds ~ ~.    ds /.\}.if t \{\.    ds ' \\k:\h'-(\\n(.wu*8/10-\*(#H)'\'\h"|\\n:u".    ds ` \\k:\h'-(\\n(.wu*8/10-\*(#H)'\`\h'|\\n:u'.    ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'^\h'|\\n:u'.    ds , \\k:\h'-(\\n(.wu*8/10)',\h'|\\n:u'.    ds ~ \\k:\h'-(\\n(.wu-\*(#H-.1m)'~\h'|\\n:u'.    ds / \\k:\h'-(\\n(.wu*8/10-\*(#H)'\z\(sl\h'|\\n:u'.\}.    \" troff and (daisy-wheel) nroff accents.ds : \\k:\h'-(\\n(.wu*8/10-\*(#H+.1m+\*(#F)'\v'-\*(#V'\z.\h'.2m+\*(#F'.\h'|\\n:u'\v'\*(#V'.ds 8 \h'\*(#H'\(*b\h'-\*(#H'.ds o \\k:\h'-(\\n(.wu+\w'\(de'u-\*(#H)/2u'\v'-.3n'\*(#[\z\(de\v'.3n'\h'|\\n:u'\*(#].ds d- \h'\*(#H'\(pd\h'-\w'~'u'\v'-.25m'\f2\(hy\fP\v'.25m'\h'-\*(#H'.ds D- D\\k:\h'-\w'D'u'\v'-.11m'\z\(hy\v'.11m'\h'|\\n:u'.ds th \*(#[\v'.3m'\s+1I\s-1\v'-.3m'\h'-(\w'I'u*2/3)'\s-1o\s+1\*(#].ds Th \*(#[\s+2I\s-2\h'-\w'I'u*3/5'\v'-.3m'o\v'.3m'\*(#].ds ae a\h'-(\w'a'u*4/10)'e.ds Ae A\h'-(\w'A'u*4/10)'E.    \" corrections for vroff.if v .ds ~ \\k:\h'-(\\n(.wu*9/10-\*(#H)'\s-2\u~\d\s+2\h'|\\n:u'.if v .ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'\v'-.4m'^\v'.4m'\h'|\\n:u'.    \" for low resolution devices (crt and lpr).if \n(.H>23 .if \n(.V>19 \\{\.    ds : e.    ds 8 ss.    ds o a.    ds d- d\h'-1'\(ga.    ds D- D\h'-1'\(hy.    ds th \o'bp'.    ds Th \o'LP'.    ds ae ae.    ds Ae AE.\}.rm #[ #] #H #V #F C.\" ========================================================================.\".IX Title "mod_perl-2.0.2::docs::api::APR::Util 3".TH mod_perl-2.0.2::docs::api::APR::Util 3 "2005-10-21" "perl v5.10.0" "User Contributed Perl Documentation".\" For nroff, turn off justification.  Always turn off hyphenation; it makes.\" way too many mistakes in technical documents..if n .ad l.nh.SH "NAME"APR::Util \- Perl API for Various APR Utilities.SH "Synopsis".IX Header "Synopsis".Vb 1\&  use APR::Util ();\&  \&  $ok = password_validate($passwd, $hash);.Ve.SH "Description".IX Header "Description"Various \s-1APR\s0 utilities that don't fit into any other group..SH "API".IX Header "API"\&\f(CW\*(C`APR::Util\*(C'\fR provides the following functions and/or methods:.ie n .Sh """password_validate""".el .Sh "\f(CWpassword_validate\fP".IX Subsection "password_validate"Validate an encrypted password hash against a plain text password(with lots of restrictions and peculiarities)..PP.Vb 1\&  $ok = password_validate($passwd, $hash);.Ve.ie n .IP "arg1: $passwd ( string )" 4.el .IP "arg1: \f(CW$passwd\fR ( string )" 4.IX Item "arg1: $passwd ( string )"Plain text password string.ie n .IP "arg2: $hash ( string )" 4.el .IP "arg2: \f(CW$hash\fR ( string )" 4.IX Item "arg2: $hash ( string )"Encrypted or encoded hash. See below for supported hash formats..ie n .IP "ret: $ok ( boolean )" 4.el .IP "ret: \f(CW$ok\fR ( boolean )" 4.IX Item "ret: $ok ( boolean )"The password either matches or not..IP "since: 2.0.00" 4.IX Item "since: 2.0.00".PPThe function handles the output of the following functions (it knowsto tell md5 and sha1 from the others, since they are have a specialpattern recognized by apr):.IP "\(bu" 4md5.Spgenerated by \f(CW\*(C`apr_md5_encode()\*(C'\fR (for which at the moment we have noperl glue, ask if you need it)..IP "\(bu" 4sha1.Spgenerated by \f(CW\*(C`apr_sha1_base64()\*(C'\fR (for which at the moment we have noperl glue, ask if you need it)..Spand it's available only since Apache 2.0.50.IP "\(bu" 4crypt.SpOn all but the following platforms: MSWin32, beos andNetWare. Therefore you probably don't want to use that feature, unlessyou know that your code will never end up running on those listedplatforms..SpMoreover on these three platforms if that function sees that the hashis not of md5 and sha1 formats, it'll do a clear to clear textmatching, always returning success, no matter what the hashed valueis..PPWarning: double check that you understand what this function does anddoes not before using it..SH "Unsupported API".IX Header "Unsupported API"\&\f(CW\*(C`APR::Socket\*(C'\fR also provides auto-generated Perl interface for a fewother methods which aren't tested at the moment and therefore their\&\s-1API\s0 is a subject to change. These methods will be finalized later as aneed arises. If you want to rely on any of the following methodsplease contact the the mod_perl development mailinglist so we can help each other take the steps necessaryto shift the method to an officially supported \s-1API\s0..ie n .Sh """filepath_name_get""".el .Sh "\f(CWfilepath_name_get\fP".IX Subsection "filepath_name_get"\&\s-1META:\s0 Autogenerated \- needs to be reviewed/completed.PP[We have File::Spec and File::Basename for this purpose, I can't seewhy this api is needed].PPreturn the final element of the pathname.PP.Vb 1\&  $ret = filepath_name_get($pathname);.Ve.ie n .IP "arg1: $pathname ( string )" 4.el .IP "arg1: \f(CW$pathname\fR ( string )" 4.IX Item "arg1: $pathname ( string )"The path to get the final element of.ie n .IP "ret: $ret ( string )" 4.el .IP "ret: \f(CW$ret\fR ( string )" 4.IX Item "ret: $ret ( string )"the final element of the path.SpFor example:.Sp.Vb 4\&  "/foo/bar/gum"    => "gum"\&  "/foo/bar/gum/"   => ""\&  "gum"             => "gum"\&  "bs\e\epath\e\estuff" => "stuff".Ve.IP "since: subject to change" 4.IX Item "since: subject to change".ie n .Sh """password_get""".el .Sh "\f(CWpassword_get\fP".IX Subsection "password_get"\&\s-1META:\s0 Autogenerated \- needs to be reviewed/completed.PPDisplay a prompt and read in the password from stdin..PP.Vb 1\&  $ret = password_get($prompt, $pwbuf, $bufsize);.Ve.ie n .IP "arg1: $prompt ( string )" 4.el .IP "arg1: \f(CW$prompt\fR ( string )" 4.IX Item "arg1: $prompt ( string )"The prompt to display.ie n .IP "arg2: $pwbuf ( string )" 4.el .IP "arg2: \f(CW$pwbuf\fR ( string )" 4.IX Item "arg2: $pwbuf ( string )"Buffer to store the password.ie n .IP "arg3: $bufsize (number)" 4.el .IP "arg3: \f(CW$bufsize\fR (number)" 4.IX Item "arg3: $bufsize (number)"The length of the password buffer..ie n .IP "ret: $ret (integer)" 4.el .IP "ret: \f(CW$ret\fR (integer)" 4.IX Item "ret: $ret (integer)".PD 0.IP "since: subject to change" 4.IX Item "since: subject to change".PD.SH "See Also".IX Header "See Also"mod_perl 2.0 documentation..SH "Copyright".IX Header "Copyright"mod_perl 2.0 and its core modules are copyrighted underThe Apache Software License, Version 2.0..SH "Authors".IX Header "Authors"The mod_perl development team and numerouscontributors.

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?