Example #1
0
 /**
  * Initialize from a string containing multiple PEM blocks.
  *
  * @param string $str
  * @return self
  */
 public static function fromPEMString($str)
 {
     $pems = PEMBundle::fromString($str)->all();
     return self::fromPEMs(...$pems);
 }
Example #2
0
 /**
  * Initialize from PEM bundle.
  *
  * @param PEMBundle $pem_bundle
  * @return self
  */
 public static function fromPEMBundle(PEMBundle $pem_bundle)
 {
     return self::fromPEMs(...$pem_bundle->all());
 }