Class: Security::InternetPassword
- Defined in:
- lib/security/password.rb
Overview
:nodoc:
Instance Attribute Summary
Attributes inherited from Password
#attributes, #keychain, #password
Class Method Summary collapse
- .add(server, account, password, options = {}) ⇒ Object
- .delete(options) ⇒ Object
- .find(options) ⇒ Object
Methods inherited from Password
Constructor Details
This class inherits a constructor from Security::Password
Class Method Details
.add(server, account, password, options = {}) ⇒ Object
94 95 96 97 98 99 100 |
# File 'lib/security/password.rb', line 94 def add(server, account, password, = {}) [:a] = account [:s] = server [:w] = password system "security add-internet-password #{flags_for_options(options)}" end |
.delete(options) ⇒ Object
106 107 108 |
# File 'lib/security/password.rb', line 106 def delete() system "security delete-internet-password #{flags_for_options(options)}" end |
.find(options) ⇒ Object
102 103 104 |
# File 'lib/security/password.rb', line 102 def find() password_from_output(`security 2>&1 find-internet-password -g #{flags_for_options(options)}`) end |