100% Latest & Updated CompTIA SY0-701 Practice Test Questions, Exam Dumps & Verified Answers!
30 Days Free Updates, Instant Download!
Question 220
An authenticated web portal sets session cookies readable to injected JavaScript and sometimes sends them over HTTP. What browser-side cookie policy directly reduces both exposures?
- Mark session cookies HttpOnly and Secure, and select a fit-for-purpose SameSite mode.
- Set extremely long cookie expiry times without changing attributes.
- Enable HTTP fallback for all logged-in pages without transport protection.
- Store tokens in a public JavaScript variable for convenient debugging.
Explanation
Correct Answer
A:Script reads and plaintext transmission are restricted while cross-site cookie behavior can be bounded. HttpOnly blocks ordinary injected JavaScript from directly reading cookie values, while Secure keeps them off plaintext HTTP requests. SameSite provides context-specific cross-site request limits; none of these substitutes for eliminating injection vulnerabilities or authenticating the service.
Incorrect Answers
B:Extended token life increases abuse duration and does not fix script or transport access. Longer token lifetimes widen the window in which a stolen session can be used and do not restrict how scripts or the browser transport cookies. Expiry is a separate session-lifecycle control, not a remedy for the two explicit exposures.
C:Any session cookie sent over plaintext may be captured by a network observer. Allowing HTTP after login permits interception or modification of session-bearing traffic even if authentication originally used TLS. Persistent HTTPS and Secure attributes are needed to avoid leaking the session to a network observer.
D:Readable script state increases the chance that injected code can steal session secrets. Public script variables are intentionally accessible to page JavaScript and any successfully injected malicious code. Moving the token there makes script theft easier, whereas properly protected cookies reduce direct exposure of the bearer secret.
Question 221
A vendor discovers that its production code-signing private key was included in a publicly accessible build log. A malicious actor could now create packages signed with the exposed key, even though previously issued authentic packages may have been valid. What is the most defensible immediate containment of the signing infrastructure?
- Revoke or distrust the compromised signing identity, generate a new key in protected custody, and change the release pipeline and consumers to use the replacement trust policy.
- Continue using the old signing key because packages already installed have passed their authenticity checks.
- Switch downloads to HTTPS while allowing the compromised private signing key to authorize all future packages.
- Require all future release packages to use an approved checksum manifest while continuing to sign it with the exposed private key.
Explanation
Correct Answer
A:Exposure of the signing private key destroys assurance that a future valid-looking signature came from the authorized vendor. Revoke or explicitly distrust that signing identity as appropriate for distribution policy, generate a replacement in a protected signing system, and update release verification policy so newly accepted packages cannot be issued with the compromised key.
Incorrect Answers
B:A check performed on an older authentic release says nothing about who can use the leaked private key tomorrow. Continuing to authorize that key permits an attacker to mint a cryptographically valid signature on malicious content. The control must change the permitted signing authority, not rely on past successful installations.
C:HTTPS protects an individual download connection against many transport attacks, but it does not restore the exclusivity of a stolen code-signing private key. An attacker who controls the signing key can create apparently valid packages and distribute them over a perfectly encrypted channel. Revoke the compromised signing authority and rotate the key.
D:A signed manifest or checksum can help detect accidental corruption of package bytes, which makes it appealing during a release-pipeline response. But a stolen signing key lets an attacker generate valid-looking signatures over malicious manifests and packages. Integrity checks tied to the compromised identity cannot restore publisher authenticity; revoke or distrust that identity and migrate both signers and consumers to a protected replacement.
Question 222
A document conversion service accepts files from unknown senders and currently runs converters with write access to application code and internal databases. Which containment design is safer?
- Allow unconstrained network access from all converter processes.
- Mount the entire production filesystem writable inside the conversion container.
- Give the converter root permissions to avoid file-open errors.
- Run each conversion in a restricted isolated process with read-only inputs and minimal output rights.
Explanation
Correct Answer
D:A file-parser exploit then has a smaller ability to modify application data or pivot into privileged services. An isolated conversion worker with minimal filesystem, process and network privileges limits what a malicious document can affect. Separate each job's temporary workspace and test that parser compromise cannot rewrite applications or read databases beyond the explicitly authorized output path.
Incorrect Answers
A:A compromised parser could contact attacker destinations and internal databases directly. An exploited document parser with unconstrained egress could call command-and-control services or probe internal databases from an otherwise legitimate conversion process. Restrict network connectivity to only the exact dependencies that processing requires, preferably none when offline conversion is feasible.
B:Shared write mounts defeat the intended isolation from application code and secrets. A writable host mount crosses the isolation boundary: malicious converter code could replace deployed application files or manipulate internal records. Use read-only input bindings and separate limited output storage rather than exposing arbitrary production paths.
C:More privilege expands the damage possible from an exploit in an untrusted document. Root rights in the converter grant an untrusted-file exploit excessive local capabilities and access to mapped resources. Running under an unprivileged, constrained identity reduces the damage possible even when the parsing library contains an exploitable memory or logic flaw.
Question 223
Newly deployed cloud VMs inherit an image with unused daemons and a wildcard instance role. Security wants a repeatable fix for all future instances. Which practice addresses both defaults?
- Rename the old image without removing unused services.
- Depend solely on monthly reports without preventing unsafe image use.
- Publish a reviewed VM baseline with unnecessary services removed and least-privilege instance permissions.
- Give all instances cloud administrator rights to simplify debugging.
Explanation
Correct Answer
C:Fixing common images and roles reduces exposure for every deployment rather than relying on per-VM cleanup. Build hardened images, close unnecessary ports and services, scope instance roles to required resources and actions, then test the baseline in automated deployment gates. This fixes the insecure template rather than relying on individual administrators to remediate each new VM.
Incorrect Answers
A:A new label does not change the running attack surface or attached privilege set. Changing the image name does not turn off the inherited listeners or restrict cloud API actions. Every new VM instantiated from the unchanged image will reproduce the same exposed daemons and permissive identity role, creating a repeatable but unsafe deployment pattern.
B:Delayed detection permits many new VMs to run with known insecure defaults. Monthly reports detect some deviations after instances have already launched and may have served traffic. Preventive image governance and least-privilege role templates are needed to stop the same weakness from entering the fleet on every rollout.
D:Broad identity authority magnifies the effect of a single compromised workload. Giving workloads administrator access lets one compromised web application change unrelated cloud resources or steal data. Debug convenience should use time-limited, audited elevation where necessary, not a universal production role that amplifies every software defect.
Question 224
A purchasing team selects new switching hardware based only on price and port count, without checking software support or signed update availability. What procurement gate should be added?
- Require a documented expected hardware lifetime but leave firmware signing and vendor security support out of acceptance.
- Require documented vendor support dates and a secure firmware maintenance path in purchase acceptance.
- Purchase obsolete models if they are slightly cheaper and skip support review.
- Approve a hardware purchase based solely on a vendor promise of future firmware fixes without a published support commitment.
Explanation
Correct Answer
B:Unsupported hardware can become impossible to remediate during its intended operating life. Request published maintenance dates, security-advisory handling, supported signed firmware updates and a patch path for the planned service life. Acceptance should establish that newly acquired switches can receive vulnerability fixes without reliance on undocumented images or unsupported hardware.
Incorrect Answers
A:A planned hardware lifespan helps budgeting and replacement forecasting, but a device can remain physically functional after the supplier stops issuing security fixes. The procurement problem explicitly includes unreviewed patch availability. Support dates and a verified firmware update process must be acceptance criteria rather than inferred from expected power-on lifetime.
C:Lower initial cost can create persistent unmanaged security and operational risk. A small acquisition discount can be outweighed by years without vendor security fixes and the resulting compensating controls or emergency replacement. Price and port count alone cannot establish acceptable lifetime security risk for critical network equipment.
D:Vendor assurances might appear to reduce maintenance risk, but a verbal or marketing promise gives no verifiable security update period or trusted delivery mechanism. Before accepting the switching equipment, procurement should document support windows and signed-firmware/secure-update capability. Otherwise a newly purchased asset may enter service already lacking reliable vulnerability remediation.
Question 225
A warehouse has closed, but the company cannot say which laptops or access points were assigned there and which remain online. What inventory control helps reconcile this gap?
- Trust an equipment hostname as a unique physical identifier without verification.
- Rely on the most recent warehouse purchasing ledger and presume every purchased device was still present at closure.
- Reconcile active network discovery against unique asset IDs, assigned site and custodian.
- Estimate the number of devices based only on purchase invoices.
Explanation
Correct Answer
C:Matching observed devices to records exposes missing, relocated or unowned equipment after closure. Match observed MAC addresses and device identities to unique serials, current site assignments, business owners and disposition records. Investigate any unmatched network device and any registered asset that cannot be located, then update custody with attributable evidence.
Incorrect Answers
A:Names can be duplicated or changed, whereas asset tags and serials support custody tracking. Hostnames are mutable settings and can be reused after imaging, so they do not alone establish which physical appliance or laptop is missing. Cross-check serial numbers and authenticated discovery observations against a stable custody ledger before closing the location discrepancy.
B:Purchase records can provide a useful initial asset count and sometimes include serial numbers, so finance data may help begin the investigation. They do not show devices moved to another site, lost in storage, loaned to staff or still active on the network. The closure problem requires reconciliation of discovery and unique identifiers against current assignments and custodians, not purchase totals alone.
D:Purchases do not establish current physical custody or whether a device remains connected. Invoices show how many devices were purchased, not where each device operates or who has custody now. Equipment may have been relocated, lost or disposed of; reliable reconciliation needs current discovery and serialized custody history.
Question 226
A shared research server stores restricted data, but nobody is assigned responsibility for patch schedules or end-of-life disposal. Which lifecycle assignment resolves the missing accountability?
- Let any available researcher make undocumented privileged decisions.
- Assign technical operations staff to reboot the server during outages without specifying patch or retirement ownership.
- Register a named server custodian with explicit patching, access and disposal responsibilities.
- Deploy an automated patch scanner to the research server without naming who acts on its findings.
Explanation
Correct Answer
C:A responsible owner can receive vulnerability findings and authorize safe retirement steps when the asset reaches end of life. Assign a named custodian and explicit obligations for access approvals, software maintenance, vulnerability decisions, retention and sanitization at retirement. Periodically verify that the owner remains active and that delegated operators can execute documented procedures.
Incorrect Answers
A:Informal rotating control obscures who must remediate security gaps or protect stored research data. Unassigned researchers may patch at incompatible times or grant privileged access without records. Research-data sensitivity requires one accountable custodian who can coordinate maintenance windows, respond to vulnerabilities and supervise controlled end-of-life handling.
B:An operations rota may improve incident response availability, but it does not name who approves security maintenance windows, handles access reviews or coordinates end-of-life protection of restricted data. The problem is long-term asset accountability rather than after-hours reboot coverage. A named custodian with documented lifecycle duties closes that gap.
D:Scanners can inventory missing updates and notify a shared queue, but automated findings alone cannot assign remediation deadlines, approve downtime or dispose of sensitive storage correctly. The server has no owner for patches or retirement. Explicit custodianship remains necessary so scanned exposures lead to controlled action and recorded disposal decisions.
Question 227
An unused portable drive is tagged general storage, but inspection shows it contains regulated patient imaging files. What inventory change is needed before the drive is transferred?
- Reclassify the drive as regulated sensitive media and apply the corresponding custody controls.
- Delete the media inventory entry while leaving the original files untouched.
- Permit transfer without custody evidence because the contents are not currently accessed.
- Enable full-volume encryption just before shipment while leaving the device classified as general storage and skipping sensitive-media custody controls.
Explanation
Correct Answer
A:The data on the drive determines restrictions for transport, storage and authorized handling. The inspection reveals regulated patient information, so the previous generic label is factually misleading. Reclassify the physical media to match its actual contents, restrict handlers and transport routes, and document who may authorize its movement.
Incorrect Answers
B:Removing the record hides the asset without protecting the regulated information it holds. Deleting the asset entry would remove traceability but leave imaging files readable on the drive. The institution needs both proper sensitivity labels and custody records, especially before the media passes to another site or supplier.
C:A dormant drive can still be lost or inspected by an unauthorized recipient. Data remains sensitive even when no application is currently using it; anyone handling a transferred drive may copy it. Chain-of-custody and access restrictions must follow the protected content during storage and movement.
D:Encryption can help protect a working device, but applying it at transfer time does not automatically sanitize existing plaintext remnants or establish who controlled the drive. This device contains regulated patient images despite its current inventory label. Reclassification, authorized handling, tracking and an appropriate transfer or sanitization process are still required under the sensitive-media policy.
Question 228
A network appliance moves between offices but the current asset register still lists its previous branch. What custody evidence should accompany physical relocation?
- Update the management IP address and network diagram for the new office but leave the device transfer and receipt ledger unchanged.
- Update an asset movement log with serial, sender, recipient, time and destination.
- Erase all previous movement entries whenever an asset changes office.
- Leave the previous branch listed to avoid upsetting historical reports.
Explanation
Correct Answer
B:Traceable transfer records establish who controlled the device at each leg of the relocation. Record the hardware serial and asset tag, releasing custodian, receiving custodian, dates, destination and receipt acknowledgement. The resulting transfer chain explains where the appliance was at each leg and which person accepted responsibility after delivery.
Incorrect Answers
A:Routing and diagrams help administrators find the appliance after relocation, but they do not establish which person released, carried and accepted the physical asset. The missing evidence is custody and accountability for the serialized device. A movement record should capture origin, destination, transfer time, sender and receiving custodian without deleting earlier movements.
C:Deleting custody history prevents investigators from reconstructing earlier transfers. Deleting earlier movements removes accountability for how the appliance reached each site. A defensible inventory preserves custody history while updating the current owner and location as an additional event.
D:Stale location records hinder asset recovery and ownership decisions during an incident. Keeping a known-wrong location may preserve report formatting but undermines incident response and recovery. The register should identify the actual receiving branch while historical movement entries retain what prior records showed.
Question 229
A hospital has already sanitized the storage in 75 retired laptops and retained individual erase results. The recycler signs a receipt containing only the total count, and two units cannot be reconciled against the outgoing inventory. Which additional safeguard closes the remaining disposal-control gap?
- Repeat the same secure-erase routine on all laptops without recording which device moved to whom.
- Keep the sanitized laptop backups for another year without examining the handoff discrepancy.
- Accept the contractor's bulk invoice as proof that every named laptop was received.
- Scan each asset's serial number against a signed transfer manifest, record custody at each handoff, and investigate any identifier mismatch.
Explanation
Correct Answer
D:A serialized, signed chain-of-custody links each sanitized device to its next holder so missing units can be located or escalated. Scan serials at dispatch and receipt, require named custody acknowledgements, and reconcile the signed manifest with hospital asset records. Escalate the two unmatched units specifically; their prior sanitation evidence does not eliminate physical-chain control obligations.
Incorrect Answers
A:Another erase does not identify whether specific serialized devices arrived at the recycler or went missing in transport. Repeating disk wiping addresses residual stored data but does not prove which two physical laptops were handed to the recycler. The remaining gap is custody reconciliation, so additional erasure without identifiers would leave the missing-unit question unanswered.
B:An extra year of sanitized-device backup retention cannot explain the gap in serial-number custody between the hospital and recycler. The case requires identifying which two assets were shipped, received and processed, with timestamps and responsible custodians. Extending data retention may create unnecessary exposure while leaving the potentially missing hardware unaccounted for.
C:An aggregate invoice lacks the unit-level identity necessary to track the hospital's two unreconciled laptops. An invoice confirming 75 units is compatible with two serialized laptops being substituted or lost during movement. Aggregate quantity does not establish that the actual hospital devices reached the recycler as intended.
Question 230
A company must retire failed solid-state drives that stored unencrypted confidential customer contracts. Their controllers no longer respond to supported sanitize or cryptographic-erase commands, and the retirement policy requires proof that data cannot be recovered. Which TWO actions are justified for these devices? Choose TWO.
- Use an approved physical-destruction process appropriate to the SSD media and obtain verifiable destruction evidence.
- Run an ordinary operating-system quick format and assume remapped flash cells are inaccessible.
- Send the untracked failed drives to general electronic recycling because they cannot be mounted.
- Record each drive serial number, custody transfers, destruction method and verification or certificate in the disposition register.
- Keep an asset-inventory entry and shipping receipt for the recycler but obtain no validated destruction record for the actual SSD media.
Explanation
Correct Answers
A:If firmware-based erase cannot execute and plaintext customer data may remain in remapped cells, a certified destructive method matched to the flash media removes the reliance on inaccessible controller commands. Verify actual destruction of the relevant storage components, not merely transport to a recycler.
D:Serialized custody and a destruction record connect each physical SSD to the approved process and resulting evidence. This is jointly needed with physical destruction: an impressive certificate is insufficient if the company cannot show that the actual contract-bearing devices were handled.
Incorrect Answers
B:Quick formatting usually changes logical metadata rather than every underlying flash cell. It cannot prove that remapped or inaccessible pages holding contracts were overwritten, especially when the controller has already failed. The required irrecoverability cannot be inferred from an OS command returning success.
C:Failure to mount a drive does not mean its flash chips are unrecoverable through specialized examination. General recycling without serialized custody creates an unnecessary disclosure path before destruction is completed. Each drive must remain traceable until evidence shows its media was destroyed under the approved procedure.
E:An inventory and shipment trail helps show where devices were sent, yet shipment is not equivalent to destroying recoverable flash contents. The drives stored unencrypted customer contracts and their controllers cannot execute logical sanitize commands. The organization needs approved physical destruction and proof tying each SSD serial number to the completed destruction process.
CompTIA Security+ (SY0-701) Practice Tests