---
name: "RDF::Crypt::Role::WithPrivateKey"
section: "3pm"
platform: "linux"
package: "librdf-crypt-perl"
version: "0.002-3"
release: "Debian 9 (Stretch)"
platforms: ["linux"]
url: "https://new.carta.tech/RDF::Crypt::Role::WithPrivateKey"
---

# RDF::Crypt::Role::WithPrivateKey(3pm)

role for objects that have public keys

## NAME

RDF::Crypt::Role::WithPublicKeys - role for objects that have public keys

## DESCRIPTION

### Attribute

- "private\_key"

  Read only; Crypt::OpenSSL::RSA; required.

### Additional Constructor Methods

- "new\_from\_file($file)"

  Given a filename containing a DER or PEM encoded RSA private key, constructs an object.

- "new\_from\_string($str)"

  Given a string containing a DER or PEM encoded RSA private key, constructs an object.

- "new\_from\_privkey($key)"

  Given a Crypt::OpenSSL::RSA private key object, constructs an object.

## SEE ALSO

RDF::Crypt, RDF::Crypt::Decrypter, RDF::Crypt::Signer.

## BUGS

Please report any bugs to \<http://rt.cpan.org/\>.

## AUTHOR

Toby Inkster \<tobyink@cpan.org\>.

## COPYRIGHT

Copyright 2010, 2012 Toby Inkster

This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.

## DISCLAIMER OF WARRANTIES

THIS PACKAGE IS PROVIDED "AS IS" AND WITHOUT ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
