
Security News
Crates.io Implements Trusted Publishing Support
Crates.io adds Trusted Publishing support, enabling secure GitHub Actions-based crate releases without long-lived API tokens.
github.com/timberio/tcp_server
Package tcp_server created to help build TCP servers faster.
go get -u github.com/firstrow/tcp_server
NOTICE: OnNewMessage
callback will receive new message only if it's ending with \n
package main
import "github.com/firstrow/tcp_server"
func main() {
server := tcp_server.New("localhost:9999")
server.OnNewClient(func(c *tcp_server.Client) {
// new client connected
// lets send some message
c.Send("Hello")
})
server.OnNewMessage(func(c *tcp_server.Client, message string) {
// new message received
})
server.OnClientConnectionClosed(func(c *tcp_server.Client, err error) {
// connection with client lost
})
server.Listen()
}
To hack on this project:
go get -u github.com/firstrow/tcp_server
)git checkout -b my-new-feature
)go test
)git commit -am 'Add some feature'
)Contribute upstream:
git remote add fork git@github.com:firstrow/tcp_server.git
)git push fork my-new-feature
)Notice: Always use the original import path by installing with go get
.
FAQs
Unknown package
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.
Security News
Crates.io adds Trusted Publishing support, enabling secure GitHub Actions-based crate releases without long-lived API tokens.
Research
/Security News
Undocumented protestware found in 28 npm packages disrupts UI for Russian-language users visiting Russian and Belarusian domains.
Research
/Security News
North Korean threat actors deploy 67 malicious npm packages using the newly discovered XORIndex malware loader.