SECURITY: Remove credential exposure from logs
- Replace full config logging with sanitized version - Credentials now show as [REDACTED] in console logs - Fixed in: enhanced-screenshot service, API routes, test files - Prevents TradingView email/password from appearing in container logs
This commit is contained in:
@@ -71,7 +71,13 @@ export async function POST(request) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
console.log('🔧 Using config:', config)
|
console.log('🔧 Using config:', {
|
||||||
|
symbol: config.symbol,
|
||||||
|
timeframe: config.timeframe,
|
||||||
|
layouts: config.layouts,
|
||||||
|
sessionId: config.sessionId,
|
||||||
|
credentials: '[REDACTED]'
|
||||||
|
})
|
||||||
|
|
||||||
let screenshots = []
|
let screenshots = []
|
||||||
let analysis = null
|
let analysis = null
|
||||||
|
|||||||
@@ -22,8 +22,14 @@ export class EnhancedScreenshotService {
|
|||||||
private static diySession: TradingViewAutomation | null = null
|
private static diySession: TradingViewAutomation | null = null
|
||||||
|
|
||||||
async captureWithLogin(config: ScreenshotConfig): Promise<string[]> {
|
async captureWithLogin(config: ScreenshotConfig): Promise<string[]> {
|
||||||
console.log('🚀 Enhanced Screenshot Service - Docker Environment (Dual Session)')
|
console.log('🚀 Enhanced Screenshot Service - Docker Environment')
|
||||||
console.log('📋 Config:', config)
|
console.log('📋 Config:', {
|
||||||
|
symbol: config.symbol,
|
||||||
|
timeframe: config.timeframe,
|
||||||
|
layouts: config.layouts,
|
||||||
|
sessionId: config.sessionId,
|
||||||
|
credentials: '[REDACTED]'
|
||||||
|
})
|
||||||
|
|
||||||
const screenshotFiles: string[] = []
|
const screenshotFiles: string[] = []
|
||||||
|
|
||||||
|
|||||||
@@ -28,7 +28,13 @@ export class EnhancedScreenshotService {
|
|||||||
|
|
||||||
async captureWithLogin(config: ScreenshotConfig): Promise<string[]> {
|
async captureWithLogin(config: ScreenshotConfig): Promise<string[]> {
|
||||||
console.log('🚀 Enhanced Screenshot Service - Docker Environment (Dual Session)')
|
console.log('🚀 Enhanced Screenshot Service - Docker Environment (Dual Session)')
|
||||||
console.log('📋 Config:', config)
|
console.log('📋 Config:', {
|
||||||
|
symbol: config.symbol,
|
||||||
|
timeframe: config.timeframe,
|
||||||
|
layouts: config.layouts,
|
||||||
|
sessionId: config.sessionId,
|
||||||
|
credentials: '[REDACTED]'
|
||||||
|
})
|
||||||
|
|
||||||
const screenshotFiles: string[] = []
|
const screenshotFiles: string[] = []
|
||||||
const { sessionId } = config
|
const { sessionId } = config
|
||||||
|
|||||||
@@ -15,7 +15,12 @@ async function testDualSessionScreenshots() {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
console.log('📋 Test Configuration:', config)
|
console.log('📋 Test Configuration:', {
|
||||||
|
symbol: config.symbol,
|
||||||
|
timeframe: config.timeframe,
|
||||||
|
layouts: config.layouts,
|
||||||
|
credentials: '[REDACTED]'
|
||||||
|
})
|
||||||
|
|
||||||
// Perform the dual-session screenshot capture
|
// Perform the dual-session screenshot capture
|
||||||
console.log('\n🔄 Starting dual-session capture...')
|
console.log('\n🔄 Starting dual-session capture...')
|
||||||
|
|||||||
Reference in New Issue
Block a user