Skip to main content

A secure AI agent response filtering and proxy service using Solana blockchain

Project description

PortaSecura

PortaSecura Logo

License: MIT with restrictions Python 3.8+ Docker Solana Website PyPI Version

PortaSecura is an enterprise-grade security solution that filters and manages AI agent outputs safely. Through a payment system utilizing PORTA tokens based on Solana blockchain, we provide secure and transparent services.

Key Features

🛡️ Advanced Security Filtering

  • Personal Information Detection and Filtering
  • Credentials and API Key Protection
  • Adult Content Filtering
  • Financial Data Protection
  • Custom Filter Support

🔄 Reverse Proxy System

  • Secure Mediation between AI Agent Server and Client
  • Real-time Content Inspection
  • Traffic Optimization
  • Load Balancing and Failover

💎 Blockchain Integration

  • PORTA Token Payments on Solana
  • Transparent Usage Metering
  • Smart Contract Automation
  • Decentralized Authentication

🔍 Monitoring and Analytics

  • Real-time Usage Monitoring
  • Detailed Filtering Analytics
  • Performance Metrics
  • Security Event Tracking

Getting Started

Prerequisites

- Python 3.8+
- Docker & Docker Compose
- Solana CLI (optional)
- Redis

Installation

Option 1: PyPI Installation (Recommended)

The easiest way to install PortaSecura is through pip:

pip install porta-secura

For development version:

pip install --pre porta-secura

With optional dependencies:

# For all features
pip install porta-secura[all]

# For blockchain features only
pip install porta-secura[blockchain]

# For proxy features only
pip install porta-secura[proxy]

Option 2: Docker Installation

For containerized deployment:

  1. Clone the repository
git clone https://github.com/portasecura/porta-secura.git
cd porta-secura
  1. Configure environment
cp .env.example .env
# Edit .env with your configuration
  1. Run with Docker
docker-compose up -d

Option 3: Source Installation

For development or customization:

git clone https://github.com/portasecura/porta-secura.git
cd porta-secura
pip install -e .

Quick Start

# Simple usage
from porta_secura import FilterManager

# Initialize the filter manager
filter_manager = FilterManager()

# Filter content
filtered_content = filter_manager.process_response(
    content="Text containing sensitive information",
    sensitivity=0.7
)

# Advanced usage with blockchain integration
from porta_secura.blockchain import PaymentProcessor
from porta_secura.core import SecurityManager

# Initialize components
payment_processor = PaymentProcessor()
security_manager = SecurityManager()

# Configure wallet
wallet_address = "your-solana-wallet-address"

# Process secured content with payment
async def process_secure_content():
    # Verify wallet balance
    if await payment_processor.check_subscription_status(wallet_address):
        # Process content
        result = filter_manager.process_response(
            content="Sensitive content to filter",
            sensitivity=0.8
        )
        # Process payment
        await payment_processor.process_payment(wallet_address, 0.01)
        return result
    return None

Package Structure

porta-secura/
├── core/
│   ├── filters.py       # Content filtering
│   ├── security.py      # Security features
│   └── proxy.py         # Reverse proxy
├── blockchain/
│   ├── solana.py        # Solana integration
│   └── wallet.py        # Wallet management
└── utils/
    ├── logging.py       # Logging utilities
    └── validation.py    # Input validation

Dependencies

Core dependencies:

fastapi>=0.68.0
uvicorn>=0.15.0
pydantic>=1.8.2
aiohttp>=3.8.1

Optional dependencies:

# Blockchain features
solana>=0.23.0
spl-token>=0.2.0

# AI features
spacy>=3.2.0
transformers>=4.19.0

Basic Usage

from porta_secura import FilterManager

# Initialize the filter manager
filter_manager = FilterManager()

# Filter content
filtered_content = filter_manager.process_response(
    content="Text containing sensitive information",
    sensitivity=0.7
)

Architecture

graph TD
    A[AI Agent Server] --> B[PortaSecura Proxy]
    B --> C[Content Filter]
    C --> D[Security Layer]
    D --> E[Blockchain Integration]
    E --> F[AI Agent Client]

Security Features

PortaSecura includes robust security measures:

  • JWT Authentication
  • API Key Management
  • Rate Limiting
  • Input Validation
  • CORS Support
  • Encrypted Data Storage
  • Audit Logging
  • DDoS Protection

Enterprise Features

High Availability

  • Load Balancing
  • Automatic Failover
  • Horizontal Scaling
  • Disaster Recovery

Monitoring

  • Real-time Metrics
  • Custom Alerting
  • Performance Analytics
  • Security Dashboards

Compliance

  • GDPR Compliance
  • HIPAA Readiness
  • SOC 2 Preparation
  • Data Encryption

Business Model

Pricing Tiers

  • Basic: 100k requests/month, $499/month

    • Basic filtering
    • Standard support
    • Single domain
  • Professional: 1M requests/month, $1,999/month

    • Advanced filtering
    • Priority support
    • Multi-domain support
    • Custom filters
  • Enterprise: Custom volume, Contact for pricing

    • Dedicated support
    • Custom integration
    • SLA guarantees
    • On-premise option

PORTA Token Utility

  • Service Payment
  • Custom Filter Marketplace
  • Governance Voting
  • Staking Rewards

Development

Testing

Run the test suite:

python -m pytest tests/

Contributing

We welcome contributions! Please see CONTRIBUTING.md for guidelines.

Code Quality

  • Linting: pre-commit run --all-files
  • Type checking: mypy porta_secura
  • Security scan: bandit -r porta_secura

Support

Enterprise Support

  • 24/7 Technical Support
  • Dedicated Account Manager
  • Custom Feature Development
  • Training and Onboarding

Community Support

Investor Information

License

This project is licensed under the MIT License with restrictions - see the LICENSE file for details.

Roadmap Highlights

  • Q2 2025: Enterprise Features Release
  • Q3 2025: Custom Filter Marketplace
  • Q4 2025: On-premise Solution
  • Q1 2026: Advanced Analytics Platform

Built with security in mind by the PortaSecura Team.

For business inquiries: business@portasecura.io
For partnerships: partnerships@portasecura.io

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

porta_secura-1.0.1.tar.gz (15.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

porta_secura-1.0.1-py3-none-any.whl (14.5 kB view details)

Uploaded Python 3

File details

Details for the file porta_secura-1.0.1.tar.gz.

File metadata

  • Download URL: porta_secura-1.0.1.tar.gz
  • Upload date:
  • Size: 15.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.0.1 CPython/3.13.1

File hashes

Hashes for porta_secura-1.0.1.tar.gz
Algorithm Hash digest
SHA256 bb3dff4ff80ad2352efb2a0251d0375eac2b8d6ecd51aa0f81be58cee2d100a6
MD5 9632021c615c07ee8febd3e42ce8f994
BLAKE2b-256 a7a8e70c27fba3868d3c24f32968ab505caac5e01332410e6dbe092043959db6

See more details on using hashes here.

File details

Details for the file porta_secura-1.0.1-py3-none-any.whl.

File metadata

  • Download URL: porta_secura-1.0.1-py3-none-any.whl
  • Upload date:
  • Size: 14.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.0.1 CPython/3.13.1

File hashes

Hashes for porta_secura-1.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 4ea30c76a8b9b755c225816f76b94378b27a9491903545dab2f6322a0cace873
MD5 3ea48f405ebc3add1d9261f050ae292a
BLAKE2b-256 c0e223c3ae730ef4665c74cc4dba8e04290cae88becb4c18c7d723322979517e

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page