main page refinement
This commit is contained in:
parent
cbfac0922a
commit
c076ee028f
@ -55,7 +55,7 @@ class DNSReconApp {
|
||||
addToGraph: document.getElementById('add-to-graph'),
|
||||
stopScan: document.getElementById('stop-scan'),
|
||||
exportResults: document.getElementById('export-results'),
|
||||
configureApiKeys: document.getElementById('configure-api-keys'),
|
||||
configureSettings: document.getElementById('configure-settings'),
|
||||
|
||||
// Status elements
|
||||
scanStatus: document.getElementById('scan-status'),
|
||||
@ -74,9 +74,9 @@ class DNSReconApp {
|
||||
modalDetails: document.getElementById('modal-details'),
|
||||
modalClose: document.getElementById('modal-close'),
|
||||
|
||||
// API Key Modal elements
|
||||
apiKeyModal: document.getElementById('api-key-modal'),
|
||||
apiKeyModalClose: document.getElementById('api-key-modal-close'),
|
||||
// Settings Modal elements
|
||||
settingsModal: document.getElementById('settings-modal'),
|
||||
settingsModalClose: document.getElementById('settings-modal-close'),
|
||||
apiKeyInputs: document.getElementById('api-key-inputs'),
|
||||
saveApiKeys: document.getElementById('save-api-keys'),
|
||||
resetApiKeys: document.getElementById('reset-api-keys'),
|
||||
@ -153,7 +153,7 @@ class DNSReconApp {
|
||||
this.exportResults();
|
||||
});
|
||||
|
||||
this.elements.configureApiKeys.addEventListener('click', () => this.showApiKeyModal());
|
||||
this.elements.configureSettings.addEventListener('click', () => this.showSettingsModal());
|
||||
|
||||
// Enter key support for target domain input
|
||||
this.elements.targetDomain.addEventListener('keypress', (e) => {
|
||||
@ -173,13 +173,13 @@ class DNSReconApp {
|
||||
});
|
||||
}
|
||||
|
||||
// API Key Modal interactions
|
||||
if (this.elements.apiKeyModalClose) {
|
||||
this.elements.apiKeyModalClose.addEventListener('click', () => this.hideApiKeyModal());
|
||||
// Settings Modal interactions
|
||||
if (this.elements.settingsModalClose) {
|
||||
this.elements.settingsModalClose.addEventListener('click', () => this.hideSettingsModal());
|
||||
}
|
||||
if (this.elements.apiKeyModal) {
|
||||
this.elements.apiKeyModal.addEventListener('click', (e) => {
|
||||
if (e.target === this.elements.apiKeyModal) this.hideApiKeyModal();
|
||||
if (this.elements.settingsModal) {
|
||||
this.elements.settingsModal.addEventListener('click', (e) => {
|
||||
if (e.target === this.elements.settingsModal) this.hideSettingsModal();
|
||||
});
|
||||
}
|
||||
if (this.elements.saveApiKeys) {
|
||||
@ -198,7 +198,7 @@ class DNSReconApp {
|
||||
document.addEventListener('keydown', (e) => {
|
||||
if (e.key === 'Escape') {
|
||||
this.hideModal();
|
||||
this.hideApiKeyModal();
|
||||
this.hideSettingsModal();
|
||||
}
|
||||
});
|
||||
|
||||
@ -687,7 +687,7 @@ class DNSReconApp {
|
||||
}
|
||||
if (this.elements.targetDomain) this.elements.targetDomain.disabled = true;
|
||||
if (this.elements.maxDepth) this.elements.maxDepth.disabled = true;
|
||||
if (this.elements.configureApiKeys) this.elements.configureApiKeys.disabled = true;
|
||||
if (this.elements.configureSettings) this.elements.configureSettings.disabled = true;
|
||||
break;
|
||||
|
||||
case 'idle':
|
||||
@ -710,7 +710,7 @@ class DNSReconApp {
|
||||
}
|
||||
if (this.elements.targetDomain) this.elements.targetDomain.disabled = false;
|
||||
if (this.elements.maxDepth) this.elements.maxDepth.disabled = false;
|
||||
if (this.elements.configureApiKeys) this.elements.configureApiKeys.disabled = false;
|
||||
if (this.elements.configureSettings) this.elements.configureSettings.disabled = false;
|
||||
break;
|
||||
}
|
||||
}
|
||||
@ -1931,20 +1931,20 @@ class DNSReconApp {
|
||||
}
|
||||
|
||||
/**
|
||||
* Show API Key modal
|
||||
* Show Settings modal
|
||||
*/
|
||||
showApiKeyModal() {
|
||||
if (this.elements.apiKeyModal) {
|
||||
this.elements.apiKeyModal.style.display = 'block';
|
||||
showSettingsModal() {
|
||||
if (this.elements.settingsModal) {
|
||||
this.elements.settingsModal.style.display = 'block';
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Hide API Key modal
|
||||
* Hide Settings modal
|
||||
*/
|
||||
hideApiKeyModal() {
|
||||
if (this.elements.apiKeyModal) {
|
||||
this.elements.apiKeyModal.style.display = 'none';
|
||||
hideSettingsModal() {
|
||||
if (this.elements.settingsModal) {
|
||||
this.elements.settingsModal.style.display = 'none';
|
||||
}
|
||||
}
|
||||
|
||||
@ -1971,7 +1971,7 @@ class DNSReconApp {
|
||||
const response = await this.apiCall('/api/config/api-keys', 'POST', keys);
|
||||
if (response.success) {
|
||||
this.showSuccess(response.message);
|
||||
this.hideApiKeyModal();
|
||||
this.hideSettingsModal();
|
||||
this.loadProviders(); // Refresh provider status
|
||||
} else {
|
||||
throw new Error(response.error || 'Failed to save API keys');
|
||||
|
@ -36,17 +36,6 @@
|
||||
<input type="text" id="target-domain" placeholder="example.com" autocomplete="off">
|
||||
</div>
|
||||
|
||||
<div class="input-group">
|
||||
<label for="max-depth">Recursion Depth</label>
|
||||
<select id="max-depth">
|
||||
<option value="1">Depth 1 - Direct relationships</option>
|
||||
<option value="2" selected>Depth 2 - Recommended</option>
|
||||
<option value="3">Depth 3 - Extended analysis</option>
|
||||
<option value="4">Depth 4 - Deep reconnaissance</option>
|
||||
<option value="5">Depth 5 - Maximum depth</option>
|
||||
</select>
|
||||
</div>
|
||||
|
||||
<div class="button-group">
|
||||
<button id="start-scan" class="btn btn-primary">
|
||||
<span class="btn-icon">[RUN]</span>
|
||||
@ -64,9 +53,9 @@
|
||||
<span class="btn-icon">[EXPORT]</span>
|
||||
<span>Download Results</span>
|
||||
</button>
|
||||
<button id="configure-api-keys" class="btn btn-secondary">
|
||||
<button id="configure-settings" class="btn btn-secondary">
|
||||
<span class="btn-icon">[API]</span>
|
||||
<span>Configure API Keys</span>
|
||||
<span>Settings</span>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
@ -104,6 +93,12 @@
|
||||
<div class="progress-bar">
|
||||
<div id="progress-fill" class="progress-fill"></div>
|
||||
</div>
|
||||
<div class="progress-placeholder">
|
||||
<span class="status-label">Reconnaissance on a large domain could take very long. Don´t try to scan Google.com.</span>
|
||||
<br>
|
||||
<span class="status-label">The main bottleneck is the request to crt.sh which is subject to harsh rate-limits.
|
||||
The processing is done via a task-queue which operates by the pronciple of highest-priority-first: Long-running-tasks will be done last.</span>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
|
||||
@ -187,16 +182,28 @@
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="api-key-modal" class="modal">
|
||||
<div id="settings-modal" class="modal">
|
||||
<div class="modal-content">
|
||||
<div class="modal-header">
|
||||
<h3>Configure API Keys</h3>
|
||||
<button id="api-key-modal-close" class="modal-close">[×]</button>
|
||||
<h3>Settings</h3>
|
||||
<button id="settings-modal-close" class="modal-close">[×]</button>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
<p class="modal-description">
|
||||
Enter your API keys for enhanced data providers. Keys are stored in memory for the current session only and are never saved to disk.
|
||||
Configure scan settings and API keys. Keys are stored in memory for the current session only.
|
||||
Only provide API-keys you dont use for anything else. Don´t enter an API-key if you don´t trust me (best practice would that you don´t).
|
||||
</p>
|
||||
<br>
|
||||
<div class="input-group">
|
||||
<label for="max-depth">Recursion Depth</label>
|
||||
<select id="max-depth">
|
||||
<option value="1">Depth 1 - Direct relationships</option>
|
||||
<option value="2" selected>Depth 2 - Recommended</option>
|
||||
<option value="3">Depth 3 - Extended analysis</option>
|
||||
<option value="4">Depth 4 - Deep reconnaissance</option>
|
||||
<option value="5">Depth 5 - Maximum depth</option>
|
||||
</select>
|
||||
</div>
|
||||
<div id="api-key-inputs">
|
||||
</div>
|
||||
<div class="button-group" style="flex-direction: row; justify-content: flex-end;">
|
||||
@ -204,7 +211,7 @@
|
||||
<span>Reset</span>
|
||||
</button>
|
||||
<button id="save-api-keys" class="btn btn-primary">
|
||||
<span>Save Keys</span>
|
||||
<span>Save API-Keys</span>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
|
Loading…
x
Reference in New Issue
Block a user