php openssl x509,PHP: openssl_x509_parse - Manual

When dealing with the purposes of a x509 crt file

the output of openssl_x509_parse gives an array with following for the purposes:

each new array ([purposes][1], [purposes][2] for example) is a new purpose check

I compared this output with the output of the command

# openssl x509 -purpose -in

the result i got was that

[purposes][x][2] quite obviously is the name of the purpose checked

[purposes][x][1] corresponds to the tested purpose (as named in [purposes][x][2]) acting as CA

[purposes][x][0] corresponds to the general availability of the purpose

[purposes] => Array

(

[1] => Array

(

[0] => 1

[1] => 1

[2] => sslclient

)

[2] => Array

(

[0] => 1

[1] => 1

[2] => sslserver

)

[3] => Array

(

[0] => 1

[1] => 1

[2] => nssslserver

)

[4] => Array

(

[0] => 1

[1] => 1

[2] => smimesign

)

[5] => Array

(

[0] => 1

[1] => 1

[2] => smimeencrypt

)

[6] => Array

(

[0] => 1

[1] => 1

[2] => crlsign

)

[7] => Array

(

[0] => 1

[1] => 1

[2] => any

)

[8] => Array

(

[0] => 1

[1] => 1

[2] => ocsphelper

)

)

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值