Ruby library for Interactsh
gem install interactsh
Interactsh::Client.new # => Initialize a new InteractSH class | [Object]
Interactsh::Client.new_domain # => Generate a new domain | [String]
Interactsh::Client.poll # => Retrieves data from the server for a specific domain | [Hash]
Interactsh.new
accepts your custom domain as an argument. See Custom Interactsh Server Installation
Interactsh::Client.new('domain.tld')
Interactsh::Client.new('domain.tld', 'your-secret-token')
require 'interactsh'
require 'net/http'
# Initialize client
client = Interactsh::Client.new
# Generate unique interaction domain
domain = client.new_domain
puts "Generated domain: #{domain}"
# Simulate an HTTP request to the domain
uri = URI("http://#{domain}")
response = Net::HTTP.get_response(uri)
puts "Made HTTP request to #{domain}"
# Poll for interactions
puts "Polling for interactions..."
interactions = client.poll(domain)
# Process interactions
interactions.each do |interaction|
puts "Request type: '#{interaction['protocol']}' from '#{interaction['remote-address']}' at #{interaction['timestamp']}"
puts "Full interaction data: #{interaction.inspect}"
end