Sha256: 25d89fb96a1ab270912fc510629e68c301e21708c8a16c8c94671c315ed19ed7

Contents?: true

Size: 449 Bytes

Versions: 4

Compression:

Stored size: 449 Bytes

Contents

module Conjur
  class KeyPair < RestClient::Resource
    include ActsAsAsset
    
    def encrypt(data)
      raise ArgumentError.new("data must not be nil") unless data
      self["encrypt"].post(data, content_type: 'application/octet-stream').body
    end
    
    def decrypt(data)
      raise ArgumentError.new("data must not be nil") unless data
      self["decrypt"].post(data, content_type: 'application/octet-stream').body
    end
  end
end

Version data entries

4 entries across 4 versions & 2 rubygems

Version Path
conjur-asset-key-pair-api-0.3.2 lib/conjur/key_pair.rb
conjur-asset-key-pair-api-0.2.2 lib/conjur/key_pair.rb
conjur-asset-key-pair-api-0.2.1 lib/conjur/key_pair.rb
conjur-asset-key-pair-0.2.1 lib/conjur/key_pair.rb