matthewspring commited on
Commit
e1cef8e
·
verified ·
1 Parent(s): 4e2888d

Upload folder using huggingface_hub

Browse files
Files changed (1) hide show
  1. index.html +444 -19
index.html CHANGED
@@ -1,19 +1,444 @@
1
- <!doctype html>
2
- <html>
3
- <head>
4
- <meta charset="utf-8" />
5
- <meta name="viewport" content="width=device-width" />
6
- <title>My static Space</title>
7
- <link rel="stylesheet" href="style.css" />
8
- </head>
9
- <body>
10
- <div class="card">
11
- <h1>Welcome to your static Space!</h1>
12
- <p>You can modify this app directly by editing <i>index.html</i> in the Files and versions tab.</p>
13
- <p>
14
- Also don't forget to check the
15
- <a href="https://huggingface.co/docs/hub/spaces" target="_blank">Spaces documentation</a>.
16
- </p>
17
- </div>
18
- </body>
19
- </html>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <!DOCTYPE html>
2
+ <html lang="en">
3
+ <head>
4
+ <meta charset="UTF-8">
5
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
6
+ <title>Secure Web Application</title>
7
+ <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css">
8
+ <style>
9
+ :root {
10
+ --primary-color: #3498db;
11
+ --secondary-color: #2980b9;
12
+ --accent-color: #e74c3c;
13
+ --light-color: #ecf0f1;
14
+ --dark-color: #2c3e50;
15
+ --success-color: #2ecc71;
16
+ --warning-color: #f39c12;
17
+ --danger-color: #e74c3c;
18
+ --shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
19
+ --border-radius: 8px;
20
+ }
21
+
22
+ * {
23
+ margin: 0;
24
+ padding: 0;
25
+ box-sizing: border-box;
26
+ font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
27
+ }
28
+
29
+ body {
30
+ background-color: var(--light-color);
31
+ color: var(--dark-color);
32
+ line-height: 1.6;
33
+ min-height: 100vh;
34
+ display: flex;
35
+ flex-direction: column;
36
+ }
37
+
38
+ header {
39
+ background-color: var(--dark-color);
40
+ color: white;
41
+ padding: 1rem;
42
+ box-shadow: var(--shadow);
43
+ position: sticky;
44
+ top: 0;
45
+ z-index: 100;
46
+ }
47
+
48
+ .header-container {
49
+ display: flex;
50
+ justify-content: space-between;
51
+ align-items: center;
52
+ max-width: 1200px;
53
+ margin: 0 auto;
54
+ width: 100%;
55
+ }
56
+
57
+ .logo {
58
+ font-size: 1.5rem;
59
+ font-weight: bold;
60
+ display: flex;
61
+ align-items: center;
62
+ gap: 0.5rem;
63
+ }
64
+
65
+ .logo i {
66
+ color: var(--primary-color);
67
+ }
68
+
69
+ .built-with {
70
+ font-size: 0.8rem;
71
+ opacity: 0.8;
72
+ }
73
+
74
+ .built-with a {
75
+ color: var(--primary-color);
76
+ text-decoration: none;
77
+ }
78
+
79
+ .built-with a:hover {
80
+ text-decoration: underline;
81
+ }
82
+
83
+ nav ul {
84
+ display: flex;
85
+ list-style: none;
86
+ gap: 1rem;
87
+ }
88
+
89
+ nav a {
90
+ color: white;
91
+ text-decoration: none;
92
+ padding: 0.5rem 1rem;
93
+ border-radius: var(--border-radius);
94
+ transition: background-color 0.3s;
95
+ }
96
+
97
+ nav a:hover {
98
+ background-color: var(--secondary-color);
99
+ }
100
+
101
+ main {
102
+ flex: 1;
103
+ max-width: 1200px;
104
+ margin: 2rem auto;
105
+ padding: 0 1rem;
106
+ width: 100%;
107
+ }
108
+
109
+ .security-section {
110
+ background-color: white;
111
+ border-radius: var(--border-radius);
112
+ box-shadow: var(--shadow);
113
+ padding: 2rem;
114
+ margin-bottom: 2rem;
115
+ }
116
+
117
+ .security-section h2 {
118
+ color: var(--primary-color);
119
+ margin-bottom: 1rem;
120
+ border-bottom: 2px solid var(--primary-color);
121
+ padding-bottom: 0.5rem;
122
+ }
123
+
124
+ .security-item {
125
+ margin-bottom: 1.5rem;
126
+ padding-bottom: 1.5rem;
127
+ border-bottom: 1px solid #eee;
128
+ }
129
+
130
+ .security-item:last-child {
131
+ border-bottom: none;
132
+ margin-bottom: 0;
133
+ padding-bottom: 0;
134
+ }
135
+
136
+ .security-status {
137
+ display: flex;
138
+ align-items: center;
139
+ gap: 0.5rem;
140
+ margin-bottom: 0.5rem;
141
+ }
142
+
143
+ .status-icon {
144
+ width: 20px;
145
+ height: 20px;
146
+ border-radius: 50%;
147
+ display: flex;
148
+ align-items: center;
149
+ justify-content: center;
150
+ font-size: 0.8rem;
151
+ }
152
+
153
+ .status-good {
154
+ background-color: var(--success-color);
155
+ color: white;
156
+ }
157
+
158
+ .status-warning {
159
+ background-color: var(--warning-color);
160
+ color: white;
161
+ }
162
+
163
+ .status-bad {
164
+ background-color: var(--danger-color);
165
+ color: white;
166
+ }
167
+
168
+ .security-title {
169
+ font-weight: bold;
170
+ margin-bottom: 0.5rem;
171
+ }
172
+
173
+ .security-description {
174
+ margin-bottom: 0.5rem;
175
+ }
176
+
177
+ .security-action {
178
+ font-style: italic;
179
+ color: var(--secondary-color);
180
+ }
181
+
182
+ .dashboard {
183
+ display: grid;
184
+ grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
185
+ gap: 1rem;
186
+ margin-top: 2rem;
187
+ }
188
+
189
+ .dashboard-card {
190
+ background-color: white;
191
+ border-radius: var(--border-radius);
192
+ box-shadow: var(--shadow);
193
+ padding: 1.5rem;
194
+ text-align: center;
195
+ transition: transform 0.3s, box-shadow 0.3s;
196
+ }
197
+
198
+ .dashboard-card:hover {
199
+ transform: translateY(-5px);
200
+ box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
201
+ }
202
+
203
+ .dashboard-card i {
204
+ font-size: 2rem;
205
+ margin-bottom: 1rem;
206
+ color: var(--primary-color);
207
+ }
208
+
209
+ .dashboard-card h3 {
210
+ margin-bottom: 0.5rem;
211
+ }
212
+
213
+ .dashboard-card p {
214
+ color: #666;
215
+ font-size: 0.9rem;
216
+ }
217
+
218
+ footer {
219
+ background-color: var(--dark-color);
220
+ color: white;
221
+ text-align: center;
222
+ padding: 1.5rem;
223
+ margin-top: auto;
224
+ }
225
+
226
+ .footer-links {
227
+ display: flex;
228
+ justify-content: center;
229
+ gap: 1rem;
230
+ margin-bottom: 1rem;
231
+ }
232
+
233
+ .footer-links a {
234
+ color: white;
235
+ text-decoration: none;
236
+ padding: 0.5rem 1rem;
237
+ border-radius: var(--border-radius);
238
+ transition: background-color 0.3s;
239
+ }
240
+
241
+ .footer-links a:hover {
242
+ background-color: var(--secondary-color);
243
+ }
244
+
245
+ @media (max-width: 768px) {
246
+ .header-container {
247
+ flex-direction: column;
248
+ gap: 1rem;
249
+ }
250
+
251
+ nav ul {
252
+ flex-wrap: wrap;
253
+ justify-content: center;
254
+ }
255
+
256
+ .dashboard {
257
+ grid-template-columns: 1fr;
258
+ }
259
+ }
260
+
261
+ @media (max-width: 480px) {
262
+ .logo {
263
+ font-size: 1.2rem;
264
+ }
265
+
266
+ nav ul {
267
+ gap: 0.5rem;
268
+ }
269
+
270
+ nav a {
271
+ padding: 0.3rem 0.6rem;
272
+ font-size: 0.9rem;
273
+ }
274
+ }
275
+ </style>
276
+ </head>
277
+ <body>
278
+ <header>
279
+ <div class="header-container">
280
+ <div class="logo">
281
+ <i class="fas fa-shield-alt"></i>
282
+ <span>SecureApp</span>
283
+ </div>
284
+ <nav>
285
+ <ul>
286
+ <li><a href="#dashboard">Dashboard</a></li>
287
+ <li><a href="#security">Security</a></li>
288
+ <li><a href="#settings">Settings</a></li>
289
+ <li><a href="#about">About</a></li>
290
+ </ul>
291
+ </nav>
292
+ <div class="built-with">
293
+ Built with <a href="https://huggingface.co/spaces/akhaliq/anycoder" target="_blank">anycoder</a>
294
+ </div>
295
+ </div>
296
+ </header>
297
+
298
+ <main>
299
+ <section id="dashboard" class="dashboard">
300
+ <div class="dashboard-card">
301
+ <i class="fas fa-network-wired"></i>
302
+ <h3>Network Isolation</h3>
303
+ <p>Strict blockade with allowlisted ports</p>
304
+ </div>
305
+ <div class="dashboard-card">
306
+ <i class="fas fa-user-shield"></i>
307
+ <h3>Non-Root Execution</h3>
308
+ <p>Least privilege user with minimal capabilities</p>
309
+ </div>
310
+ <div class="dashboard-card">
311
+ <i class="fas fa-file-lock"></i>
312
+ <h3>Read-Only Filesystem</h3>
313
+ <p>Full read-only root with tmpfs for temporaries</p>
314
+ </div>
315
+ <div class="dashboard-card">
316
+ <i class="fas fa-filter"></i>
317
+ <h3>Seccomp Filtering</h3>
318
+ <p>Allowlisted syscalls with >80% block rate</p>
319
+ </div>
320
+ </section>
321
+
322
+ <section id="security" class="security-section">
323
+ <h2>Security Controls</h2>
324
+
325
+ <div class="security-item">
326
+ <div class="security-status">
327
+ <div class="status-icon status-good">
328
+ <i class="fas fa-check"></i>
329
+ </div>
330
+ <span class="security-title">Network Isolation</span>
331
+ </div>
332
+ <p class="security-description">Current: Strict Blockade with allowlisted single API port on loopback</p>
333
+ <p class="security-action">Action: Maintain current configuration with periodic audits</p>
334
+ </div>
335
+
336
+ <div class="security-item">
337
+ <div class="security-status">
338
+ <div class="status-icon status-good">
339
+ <i class="fas fa-check"></i>
340
+ </div>
341
+ <span class="security-title">Non-Root Execution</span>
342
+ </div>
343
+ <p class="security-description">Current: Dedicated unprivileged user (llm_agent) with minimal capabilities</p>
344
+ <p class="security-action">Action: Regular capability audits and reduction</p>
345
+ </div>
346
+
347
+ <div class="security-item">
348
+ <div class="security-status">
349
+ <div class="status-icon status-good">
350
+ <i class="fas fa-check"></i>
351
+ </div>
352
+ <span class="security-title">Read-Only Filesystem</span>
353
+ </div>
354
+ <p class="security-description">Current: Full read-only root with tmpfs for logs and cache</p>
355
+ <p class="security-action">Action: Monitor tmpfs usage and adjust sizes as needed</p>
356
+ </div>
357
+
358
+ <div class="security-item">
359
+ <div class="security-status">
360
+ <div class="status-icon status-good">
361
+ <i class="fas fa-check"></i>
362
+ </div>
363
+ <span class="security-title">Seccomp Filtering</span>
364
+ </div>
365
+ <p class="security-description">Current: Allowlisted essential syscalls with >80% block rate</p>
366
+ <p class="security-action">Action: Regular syscall audit and profile updates</p>
367
+ </div>
368
+
369
+ <div class="security-item">
370
+ <div class="security-status">
371
+ <div class="status-icon status-good">
372
+ <i class="fas fa-check"></i>
373
+ </div>
374
+ <span class="security-title">AppArmor/SELinux</span>
375
+ </div>
376
+ <p class="security-description">Current: Mandatory custom profile enforcing access controls</p>
377
+ <p class="security-action">Action: Profile updates with each application version</p>
378
+ </div>
379
+ </section>
380
+ </main>
381
+
382
+ <footer>
383
+ <div class="footer-links">
384
+ <a href="#privacy">Privacy Policy</a>
385
+ <a href="#terms">Terms of Service</a>
386
+ <a href="#contact">Contact Us</a>
387
+ </div>
388
+ <p>&copy; 2023 SecureApp. All rights reserved.</p>
389
+ </footer>
390
+
391
+ <script>
392
+ // Security dashboard interaction
393
+ document.addEventListener('DOMContentLoaded', function() {
394
+ const dashboardCards = document.querySelectorAll('.dashboard-card');
395
+
396
+ dashboardCards.forEach(card => {
397
+ card.addEventListener('click', function() {
398
+ // Simple visual feedback
399
+ this.style.transform = 'scale(0.98)';
400
+ setTimeout(() => {
401
+ this.style.transform = '';
402
+ }, 150);
403
+ });
404
+ });
405
+
406
+ // Smooth scrolling for navigation links
407
+ document.querySelectorAll('a[href^="#"]').forEach(anchor => {
408
+ anchor.addEventListener('click', function (e) {
409
+ e.preventDefault();
410
+ const targetId = this.getAttribute('href');
411
+ const targetElement = document.querySelector(targetId);
412
+
413
+ if (targetElement) {
414
+ targetElement.scrollIntoView({
415
+ behavior: 'smooth'
416
+ });
417
+ }
418
+ });
419
+ });
420
+ });
421
+
422
+ // Security status checks (simulated)
423
+ function checkSecurityStatus() {
424
+ // In a real application, this would make API calls to check security status
425
+ console.log('Performing security status checks...');
426
+
427
+ // Simulate status updates
428
+ setTimeout(() => {
429
+ const statusIcons = document.querySelectorAll('.status-icon');
430
+ statusIcons.forEach(icon => {
431
+ if (Math.random() > 0.8) {
432
+ icon.classList.remove('status-good');
433
+ icon.classList.add('status-warning');
434
+ icon.innerHTML = '<i class="fas fa-exclamation-triangle"></i>';
435
+ }
436
+ });
437
+ }, 2000);
438
+ }
439
+
440
+ // Initialize security checks
441
+ checkSecurityStatus();
442
+ </script>
443
+ </body>
444
+ </html>