Class: AppMap::Handler::OpenSSLHandler

Inherits:
FunctionHandler show all
Defined in:
lib/appmap/handler/open_ssl_handler.rb

Constant Summary

Constants inherited from AppMap::Hook::Method

AppMap::Hook::Method::HOOK_DISABLE_KEY

Constants included from AppMap::Hook::RecordAround

AppMap::Hook::RecordAround::APPMAP_OUTPUT_DIR

Instance Attribute Summary

Attributes inherited from AppMap::Hook::Method

#arity, #hook_class, #hook_method, #hook_package, #parameters, #record_around

Instance Method Summary collapse

Methods inherited from FunctionHandler

#handle_return

Methods inherited from AppMap::Hook::Method

#activate, #call, #initialize

Methods included from AppMap::Hook::RecordAround

#record_around?, #record_around_after, #record_around_before

Constructor Details

This class inherits a constructor from AppMap::Hook::Method

Instance Method Details

#handle_call(receiver, args) ⇒ Object



6
7
8
9
10
11
12
13
# File 'lib/appmap/handler/open_ssl_handler.rb', line 6

def handle_call(receiver, args)
  super.tap do |event|
    algorithm = receiver.name
    event.receiver[:labels] ||= []
    label = [ 'crypto.algorithm', algorithm ].join('.')
    event.receiver[:labels] << label unless event.receiver[:labels].include?(label)
  end
end