v0.2.2 - Working on config setup

This commit is contained in:
Your Name
2025-09-05 19:48:49 -04:00
parent 6c10713e18
commit 9a29ea51e3
19 changed files with 2378 additions and 574 deletions

113
relay.log
View File

@@ -1,83 +1,50 @@
=== C Nostr Relay Server ===
[SUCCESS] Database connection established
[INFO] Initializing configuration system...
[INFO] Configuration directory: %s
/home/teknari/.config/c-relay
[INFO] Configuration file: %s
/home/teknari/.config/c-relay/c_relay_config_event.json
[INFO] Initializing configuration database statements...
[SUCCESS] Configuration database statements initialized
[INFO] Generating missing configuration file...
[INFO] Using private key from environment variable
[INFO] Creating configuration Nostr event...
[SUCCESS] Configuration Nostr event created successfully
Event ID: 03021d58b91941a3bb9284ee704e069c50c9ac09a20eb049d8de676757dde83a
Public Key: 8d8fbfb027872f13ed09e9e61f1d09473f3bec24bcfa9183e76cc1ceb789eb5e
[INFO] Stored admin public key in configuration database
Admin Public Key: 8d8fbfb027872f13ed09e9e61f1d09473f3bec24bcfa9183e76cc1ceb789eb5e
[SUCCESS] Configuration file written successfully
File: /home/teknari/.config/c-relay/c_relay_config_event.json
[SUCCESS] Configuration file generated successfully
[INFO] Loading configuration from all sources...
[INFO] Configuration file found, attempting to load...
[INFO] Loading configuration from file...
[INFO] Validating configuration event...
[INFO] Configuration event structure validation passed
[INFO] Configuration tags validation passed (%d tags)
Found 27 configuration tags
[WARNING] Signature verification not yet implemented - accepting event
[SUCCESS] Applied configuration from file
Applied 27 configuration values
[SUCCESS] Configuration event validation and application completed
[SUCCESS] Configuration loaded from file successfully
[SUCCESS] File configuration loaded successfully
[INFO] Loading configuration from database...
[SUCCESS] Database configuration validated (%d entries)
Found 27 configuration entries
[SUCCESS] Database configuration loaded
[INFO] Applying configuration to global variables...
[SUCCESS] Configuration applied to global variables
[SUCCESS] Configuration system initialized successfully
[SUCCESS] Relay information initialized with default values
[INFO] Initializing NIP-13 Proof of Work configuration
[INFO] PoW configured in basic validation mode
[INFO] PoW Configuration: enabled=true, min_difficulty=0, validation_flags=0x1, mode=full
[INFO] Initializing NIP-40 Expiration Timestamp configuration
[INFO] Expiration Configuration: enabled=true, strict_mode=true, filter_responses=true, grace_period=300 seconds
[INFO] Subscription limits: max_per_client=25, max_total=5000
[INFO] Starting relay server...
[INFO] Starting libwebsockets-based Nostr relay server...
[SUCCESS] WebSocket relay started on ws://127.0.0.1:8888
[INFO] HTTP request received
[INFO] Handling NIP-11 relay information request
[SUCCESS] NIP-11 relay information served successfully
[INFO] HTTP request received
[INFO] Handling NIP-11 relay information request
[SUCCESS] NIP-11 relay information served successfully
[INFO] WebSocket connection established
[INFO] Received WebSocket message
[INFO] Handling EVENT message with full NIP-01 validation
[SUCCESS] Event stored in database
[SUCCESS] Event validated and stored successfully
[INFO] WebSocket connection closed
[INFO] WebSocket connection established
[INFO] Received WebSocket message
[INFO] Handling EVENT message with full NIP-01 validation
[SUCCESS] Event stored in database
[SUCCESS] Event validated and stored successfully
[INFO] WebSocket connection closed
[INFO] WebSocket connection established
[INFO] Received WebSocket message
[INFO] Handling EVENT message with full NIP-01 validation
[WARNING] Event rejected: expired timestamp
[INFO] WebSocket connection closed
[INFO] WebSocket connection established
[INFO] Received WebSocket message
[INFO] Handling EVENT message with full NIP-01 validation
[SUCCESS] Event stored in database
[SUCCESS] Event validated and stored successfully
[INFO] WebSocket connection closed
[INFO] WebSocket connection established
[INFO] Received WebSocket message
[INFO] Handling EVENT message with full NIP-01 validation
[SUCCESS] Event stored in database
[SUCCESS] Event validated and stored successfully
[INFO] WebSocket connection closed
[INFO] WebSocket connection established
[INFO] Received WebSocket message
[INFO] Handling EVENT message with full NIP-01 validation
[SUCCESS] Event stored in database
[SUCCESS] Event validated and stored successfully
[INFO] WebSocket connection closed
[INFO] WebSocket connection established
[INFO] Received WebSocket message
[INFO] Handling EVENT message with full NIP-01 validation
[WARNING] Event rejected: expired timestamp
[INFO] WebSocket connection closed
[INFO] WebSocket connection established
[INFO] Received WebSocket message
[INFO] Handling REQ message for persistent subscription
[INFO] Added subscription 'filter_test' (total: 1)
[INFO] Executing SQL: SELECT id, pubkey, created_at, kind, content, sig, tags FROM events WHERE 1=1 AND kind IN (1) ORDER BY created_at DESC LIMIT 10
[INFO] Query returned 10 rows
[INFO] Total events sent: 10
[INFO] Received WebSocket message
[INFO] Removed subscription 'filter_test' (total: 0)
[INFO] Closed subscription: filter_test
[INFO] WebSocket connection closed
[WARNING] Subscription '<27><><15>a' not found for removal
[INFO] WebSocket connection established
[INFO] Received WebSocket message
[INFO] Handling EVENT message with full NIP-01 validation
[SUCCESS] Event stored in database
[SUCCESS] Event validated and stored successfully
[INFO] WebSocket connection closed
[INFO] WebSocket connection established
[INFO] Received WebSocket message
[INFO] Handling EVENT message with full NIP-01 validation
[SUCCESS] Event stored in database
[SUCCESS] Event validated and stored successfully
[INFO] WebSocket connection closed
[INFO] HTTP request received
[INFO] Handling NIP-11 relay information request
[SUCCESS] NIP-11 relay information served successfully