Metasploit mailing list archives
Re: How-to update host information
From: "HD Moore" <x () hdm io>
Date: Sun, 19 Oct 2014 19:43:58 -0500
Hi Jon, You can edit a host via psql or just the irb console in Metasploit. For example, just do: msf> irb From this prompt, you can do: irb> host = Mdm::Host.where(address: '1.1.1.1'); host.hostname = 'BugServer'; host.save! Keep in mind we normally split up things by workspace, so if you have multiple projects/workspaces: irb> host = framework.workspace.hosts.where(address: '1.1.1.1') Hope this helps, -HD
-----Original Message----- From: framework [mailto:framework-bounces () spool metasploit com] On Behalf Of Jon Molesa Sent: Sunday, October 19, 2014 7:19 PM To: framework () spool metasploit com Subject: [framework] How-to update host information Hello, I'm new here. Could someone please tell me how I can update information for a host? I haven't tried importing it via a csv, but right now I just want to know if it is possible to do in msfconsole. I have a hostname for an IP address that I have previously imported. I would like to update the record for that IP to include the hostname. hosts -h doesn't reveal support for updating a host record. Lastly, if the answer is to import the data via a csv file, I would like to know if I could drop into a sql shell and just run an update command? Perhaps something built into the irb shell. Thank you. -- Jon Molesa rjmolesa () consoltec net _______________________________________________ https://dev.metasploit.com/mailman/listinfo/framework
_______________________________________________ https://dev.metasploit.com/mailman/listinfo/framework
Current thread:
- How-to update host information Jon Molesa (Oct 19)
- Re: How-to update host information HD Moore (Oct 19)