-
Notifications
You must be signed in to change notification settings - Fork 11
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #16 from Escape-Technologies/feat/addresses-metadata
Feat/addresses metadata
- Loading branch information
Showing
9 changed files
with
75 additions
and
19 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -11,4 +11,7 @@ testers | |
/goctopus | ||
|
||
dist/ | ||
.env | ||
.env | ||
|
||
# root go files (often used for testing / prototyping) | ||
/*.go |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
package goctopus | ||
|
||
import ( | ||
"github.com/Escape-Technologies/goctopus/pkg/address" | ||
out "github.com/Escape-Technologies/goctopus/pkg/output" | ||
) | ||
|
||
// Fingerprints a single address and outputs a slice of FingerprintOutput. | ||
func FingerprintAddress(addr *address.Addr) []*out.FingerprintOutput { | ||
outputSlice := make([]*out.FingerprintOutput, 0) | ||
output := make(chan *out.FingerprintOutput, 1) | ||
addresses := make(chan *address.Addr, 1) | ||
addresses <- addr | ||
close(addresses) | ||
go FingerprintAddresses(addresses, output) | ||
for fingerprintOutput := range output { | ||
outputSlice = append(outputSlice, fingerprintOutput) | ||
} | ||
return outputSlice | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters