Research
Security News
Malicious npm Packages Inject SSH Backdoors via Typosquatted Libraries
Socket’s threat research team has detected six malicious npm packages typosquatting popular libraries to insert SSH backdoors.
dnsmadeeasy-rest-api
Advanced tools
Add this line to your application's Gemfile:
gem 'dnsmadeeasy-rest-api'
And then execute:
$ bundle
Or install it yourself:
$ gem install dnsmadeeasy-rest-api
Start by creating a new instance of the DnsMadeEasy
class, and passing your api key and secret.
api = DnsMadeEasy.new('awesome-api-key', 'super-secret-and-awesome-api-secret')
Optionally, you can connect to the sandbox API if you want to play around.
api = DnsMadeEasy.new('awesome-api-key', 'super-secret-and-awesome-api-secret', sandbox=TRUE)
All return values are the direct JSON responses from DNS Made Easy converted into a Hash.
See: https://api-docs.dnsmadeeasy.com/
To retrieve all domains:
api.domains
To retreive the id of a domain by the domain name:
api.get_id_by_domain('hello.example.com')
To retrieve the full domain record by domain name:
api.domain('hello.example.com')
To create a domain:
api.create_domain('hello.example.com')
# Multiple domains can be created by:
api.create_domains(['hello.example.com', 'sup.example.com'])
To delete a domain:
api.delete_domain('hello.example.com')
To retrieve all records for a given domain name:
api.records_for('hello.example.com')
To find the record id for a given domain, name, and type:
This finds the id of the A record 'woah.hello.example.com'.
api.find_record_id('hello.example.com', 'woah', 'A')
To delete a record by domain name and record id (the record id can be retrieved from find_record_id
:
api.delete_record('hello.example.com', 123)
# To delete multiple records:
api.delete_records('hello.example.com', [123, 143])
# To delete all records in the domain:
api.delete_all_records('hello.example.com')
To create a record:
api.create_record('hello.example.com', 'woah', 'A', '127.0.0.1', { 'ttl' => '60' })
api.create_a_record('hello.example.com', 'woah', '127.0.0.1', {})
api.create_aaaa_record('hello.example.com', 'woah', '127.0.0.1', {})
api.create_ptr_record('hello.example.com', 'woah', '127.0.0.1', {})
api.create_txt_record('hello.example.com', 'woah', '127.0.0.1', {})
api.create_cname_record('hello.example.com', 'woah', '127.0.0.1', {})
api.create_ns_record('hello.example.com', 'woah', '127.0.0.1', {})
api.create_spf_record('hello.example.com', 'woah', '127.0.0.1', {})
# Arguments are: domain_name, name, priority, value, options = {}
api.create_mx_record('hello.example.com', 'woah', 5, '127.0.0.1', {})
# Arguments are: domain_name, name, priority, weight, port, value, options = {}
api.create_srv_record('hello.example.com', 'woah', 1, 5, 80, '127.0.0.1', {})
# Arguments are: domain_name, name, value, redirectType, description, keywords, title, options = {}
api.create_httpred_record('hello.example.com', 'woah', '127.0.0.1', 'STANDARD - 302', 'a description', 'keywords', 'a title', {})
To update a record:
api.update_record('hello.example.com', 123, 'woah', 'A', '127.0.1.1', { 'ttl' => '60' })
To update several records:
api.update_records('hello.example.com', [{'id'=>123, 'name'=>'buddy', 'type'=>'A','value'=>'127.0.0.1'}], { 'ttl' => '60' })
To get the number of API requests remaining after a call:
api.requests_remaining
Information is not available until an API call has been made
To get the API request total limit after a call:
api.request_limit
Information is not available until an API call has been made
git checkout -b my-new-feature
)git commit -am 'Add some feature'
)git push origin my-new-feature
)FAQs
Unknown package
We found that dnsmadeeasy-rest-api demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 3 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Security News
Socket’s threat research team has detected six malicious npm packages typosquatting popular libraries to insert SSH backdoors.
Security News
MITRE's 2024 CWE Top 25 highlights critical software vulnerabilities like XSS, SQL Injection, and CSRF, reflecting shifts due to a refined ranking methodology.
Security News
In this segment of the Risky Business podcast, Feross Aboukhadijeh and Patrick Gray discuss the challenges of tracking malware discovered in open source softare.