OAuthomatic::SecretStorage - Save and restore confidential OAuth tokens
version 0.0202
Interface defining methods used to save and restore various credentials. Implementations should use some kind of reasonably secure persistent storage, to preserve data over reruns.
Note: methods below are parameterless (except saved tokens), but should operate on access to specific remote site. Typical implementation would have required parameers like site_name and password_group in the constructor.
site_name
password_group
See OAuthomatic::SecretStorage::Keyring for default implementation (and example).
Return saved client tokens (client_key, client_secret), or undef if those were not (yet) saved. Returns OAuthomatic::Types::ClientCred.
Save client tokens for future use.
Parameter is OAuthomatic::Types::ClientCred.
Never called if get_client_cred always returns some data. This method is used to save keys user provided after beint interactively asked.
Clear client tokens, if any are saved.
Called in case restored tokens turn out invalid, expired, etc.
Restore previously saved token and secret (access token, access secret), or undef if those were not (yet) saved. Returns OAuthomatic::Types::ClientCred.
Saves token for future use, to be preserved over program restarts. Parameter is of type OAuthomatic::Types::ClientCred.
Clear token, if it was saved. Called in case token is found to be wrong or expired.
Marcin Kasperski <Marcin.Kasperski@mekk.waw.pl>
This software is copyright (c) 2015 by Marcin Kasperski.
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.
To install OAuthomatic, copy and paste the appropriate command in to your terminal.
cpanm
cpanm OAuthomatic
CPAN shell
perl -MCPAN -e shell install OAuthomatic
For more information on module installation, please visit the detailed CPAN module installation guide.