CyberGo

website·Indexed 30 days ago

https://www.cybergo.dev

A collection of high-performance, production-ready Go open source libraries providing modules for JSON, JWT, HTTPC, HTML, DD, and ENV, including features such as JSONPath and streaming processing.

Tokens
8.3K
Snippets
2
Records
97
Agent score
50%

What's inside CyberGo

  1. Overview of CyberGo JWT Library

    CyberGo JWT is a production-grade authentication library for Go. It supports 12 different signing algorithms across four categories: HMAC, RSA, RSA-PSS, and ECDSA. The library provides a thread-safe implementation for token generation, validation, refreshing, revocation, blacklisting, and rate limiting.
  2. Overview of CyberGo HTTPC

    CyberGo HTTPC is a secure, high-performance HTTP client library for the Go language. It is designed for microservices communication and high-concurrency API call scenarios. Key features include:

    • Forced TLS 1.2+ encryption
    • SSRF (Server-Side Request Forgery) protection
    • Intelligent exponential backoff retries
    • Onion-model middleware chains
    • Connection pool management
    • Automatic Result lifecycle management
  3. Overview of CyberGo JSON Library

    CyberGo JSON is a high-performance, thread-safe Go JSON processing library designed as a seamless replacement for the standard encoding/json library. Key features include:

    • JSONPath Support: Advanced path queries for data extraction.
    • Streaming & Batching: Support for JSONL (JSON Lines) and batch processing of operations.
    • Type Safety: Generic APIs for compile-time type checking (Go 1.18+).
    • Validation: Built-in JSON Schema validation and dangerous pattern detection.
    • Performance: Intelligent caching, pre-parsing, and parallel iteration for large datasets.
  4. Overview of the CyberGo library collection

    CyberGo is a collection of high-performance, production-ready open-source libraries for the Go programming language. It is designed for high-concurrency production environments with a focus on lightweight design and minimal dependencies. The collection includes components for JSON processing, JWT authentication, secure HTTP clients, HTML extraction, structured logging, and environment variable management.
  5. Overview of CyberGo DD Structured Logging Library

    CyberGo DD is a high-performance, thread-safe structured logging library for Go. It features flexible output target configuration, automatic file rotation, sensitive data filtering, asynchronous audit logging, HMAC integrity signing, and low-allocation optimizations to ensure security and reliability in production environments.
  6. Overview of CyberGo html library

    CyberGo html is a high-performance Go library designed for HTML extraction and cleaning. It features intelligent article recognition, automatic detection of 15+ character encodings, and support for multiple output formats including Markdown and JSON. It is suitable for web scraping, crawlers, and content collection scenarios. Key capabilities include link and media extraction, concurrent batch processing, pluggable auditing pipelines, and multi-layer security protections.
  7. Overview of CyberGo env for secure environment variable management

    CyberGo env is a high-security Go library for managing environment variables. It supports automatic detection and loading of .env, JSON, and YAML formats with type-safe conversion. Key security features include SecureValue for memory locking and automatic zeroing, shard-lock thread safety, variable expansion using ${VAR} syntax, struct mapping via env tags, and comprehensive audit logging. It is designed for microservices and cloud-native configuration management.
  8. Secure CyberGo html deployments

    Implement a three-layer defense architecture (Input, Processing, and Audit). Use MaxInputSize and MaxDepth to prevent resource exhaustion, apply HighSecurityConfig for high-security presets, and implement path traversal protection and HTML content cleaning.
  9. Optimize CyberGo DD Logging Performance

    To achieve maximum performance in high-concurrency scenarios, CyberGo DD provides several optimization strategies:

    • Low-Allocation Techniques: Use sync.Pool for object reuse to reduce GC pressure.
    • Buffered Writing: Configure BufferedWriter to reduce the frequency of system calls.
    • Sampling & Frequency Control: Implement logging sampling strategies to limit the volume of logs.
    • Level Pre-checking: Check log levels before performing expensive allocations or string formatting to avoid unnecessary overhead.
  10. Handle file uploads and downloads with CyberGo HTTPC

    CyberGo HTTPC provides specialized functionality for file transfers, including multi-file uploads using WithFile and WithFormData, streaming downloads via Download, and support for resuming interrupted downloads with ResumeDownload. It includes built-in SHA-256 checksum verification, file conflict resolution, cleanup semantics, and support for UNC paths for enhanced security.
  11. Extend and test CyberGo html content extraction

    CyberGo html allows customization of content recognition logic through the implementation of custom Scorer algorithms and ContentNode traversal. For testing, developers should use mock data construction and the Extractor interface mock to ensure reliable unit tests for custom extraction logic.
  12. Integrate CyberGo html with net/http for web scraping

    CyberGo html can be integrated with the Go standard library net/http for production-grade web content collection. Key implementation patterns include using a Processor singleton in web services, implementing exponential backoff retry strategies, managing timeouts, and utilizing automatic GBK encoding detection for page scraping.