dark-enstein / scour Goto Github PK
View Code? Open in Web Editor NEWjust not curl
License: MIT License
just not curl
License: MIT License
The default size of your byte slice (1024) is not sufficient to hold the entire response.
e.g. when you do
make build
./build/scour example.com
The response gets truncated because the byte size is not sufficient enough. You could increase the byte size to 2048 and it would work but It isn't efficient that way because there could be a situation when someone tries to scour a bigger site.
You can address this by dynamically resizing the byte slice by using io.ReadAll
func ReadAll(r Reader) ([]byte, error)
ReadAll reads from r until an error or EOF and returns the data it read. A successful call returns err == nil, not err == EOF. Because ReadAll is defined to read from src until EOF, it does not treat an EOF from Read as an error to be reported.
//res := make([]byte, 1024)
//i, err := resp.Body.Read(res)
body, err := io.ReadAll(resp.Body)
...
Hiya, The abstract-unix-socket
shorthand flag (aus
) is causing a panic.
Shorthand flags typically refer to flags with a single letter. Shorthand flags are meant to provide a concise and quick way for users to specify certain options. Conventionally, they are limited to a single letter to keep the command-line interface readable and consistent.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.