Permalink
Browse files

document how to spoof

  • Loading branch information...
Ilan Rabinovitch
Ilan Rabinovitch committed May 3, 2012
1 parent 6d82a91 commit e19fdcd496c3bfd65e632bc8981e9c3d079aa7ce
Showing with 9 additions and 1 deletion.
  1. +9 −1 README.md
View
@@ -16,7 +16,6 @@ Ganglia::GMetric.send("127.0.0.1", 8670, {
:dmax => 300,
:group => 'test'
})
-```
## Example: Generating the Meta and Metric packets
@@ -38,8 +37,17 @@ s = UDPSocket.new
s.connect("127.0.0.1", 8670)
s.send g[0], 0
s.send g[1], 0
+
```
+## Spoofing Hostname in gmetrics ##
+To spoof a hostname with the gmetric library you will need to add the following keys to your gmetric.
+This works with both GMetric.send() and GMetric.pack().
+
+* spoof - takes a value of 1 or True
+* hostname - expects a value of <ip>:<hostname>.
+
+
### License
The MIT License, Copyright (c) 2009 Ilya Grigorik

0 comments on commit e19fdcd

Please sign in to comment.