Quiz collegato alla guida · Medio Livello
Quiz sull'esecuzione del codice per gli agenti
Testa il modo in cui i sandbox degli agenti isolano il codice scritto sul modello: contenitori rispetto a microVM e gVisor, limiti in uscita dalla rete e limiti di risorse come i timeout.
Domanda 1 di 8
Why is code written by an AI agent treated as untrusted by default?
Anteprima di ogni domanda8 domande
Le risposte e le spiegazioni vengono visualizzate mentre rispondi al quiz.
- Why is code written by an AI agent treated as untrusted by default?
- Because models cannot write working code
- Because it can be buggy, wasteful or shaped by prompt injection
- Because interpreted languages are always insecure
- Because operating systems block AI-generated code
- What is the main security weakness of standard containers compared with microVMs?
- They cannot limit memory
- They take minutes to start
- They share the host's kernel
- They cannot run Python
- What does gVisor add to reduce risk from untrusted code?
- A user-space kernel that intercepts system calls
- A hardware security chip
- A faster file system
- An antivirus scanner for Python packages
- Firecracker microVMs were originally built by AWS to power which kind of services?
- Video streaming
- Email delivery
- Search indexing
- Lambda and Fargate
- Why is restricting outbound network access often considered the most important sandbox control when prompt injection is possible?
- It makes code run faster
- It prevents code from sending data or secrets to outside servers
- It stops the model from generating code
- It lowers memory usage
- Which control specifically defends against a fork bomb?
- A read-only file system
- A network allowlist
- A cap on the number of processes via cgroups
- Removing environment variables
- What is the recommended way to give sandboxed code access to a credential it genuinely needs?
- Put the API key in an environment variable
- Hard-code it into the prompt
- Store it in the scratch directory
- Route access through a narrow proxy or tool call instead of exposing the secret
- Which statement reflects the guide's warning about a common misconception?
- A sandbox limits damage from code but does not make the agent's answers correct or its granted tools harmless
- Sandboxes make agents completely safe
- Sandboxes are only needed for compiled languages
- WebAssembly sandboxes cannot run Python