AP Subject A 18: DNS, HTTP, TLS, and Mail Communication

DNS roles and TTL, HTTP status codes, cookies, sessions and caching, TLS in HTTPS, HTTP/3 over QUIC, and SMTP, POP3 and IMAP for AP Subject A, with a URL trace and five original questions.

応用情報技術者試験科目AネットワークDNSHTTP電子メール

AP Subject A · Installment 18 · An independent study resource for the 2026 exam and Syllabus Ver.7.2. It is not affiliated with IPA and does not guarantee a pass. Open the series hub

2026 exam basis · Revised/source-checked 2026-10-21

Learning index

  1. Official scope and terms 2. URL-to-page flow 3. DNS 4. HTTP 5. TLS 6. HTTP versions 7. Mail 8. Exam traps 9. Quick sheet and review 10. Questions

1. Official scope and terms

This installment maps to IPA Ver.7.2, Major Category 3 / Middle Category 10 Network: 3. 通信プロトコル > (1) プロトコルとインタフェース > ⑤ アプリケーション層のプロトコル on PDF 49 / printed 45, and 5. ネットワーク応用 > (1) インターネット > ① 電子メール・② Web on PDF 51 / printed 47. These are non-contiguous; PDF 50 / printed 46 is not claimed as an AP18 content page. AP16 transport and AP17 IP routing are linked here in one sentence each, not retaught.

KO JA EN Role
재귀 리졸버 再帰リゾルバ recursive resolver finds answers for clients and can cache
권한 서버 権威サーバ authoritative server serves original data for a DNS zone
유효 시간 TTL time to live normal cache freshness bound
요청/응답 リクエスト/レスポンス request/response HTTP message exchange
쿠키 Cookie cookie client-stored scoped data sent on matching requests
세션 セッション session logical state, often server-side behind an opaque ID
캐시 キャッシュ cache stored reusable response representation
메일 사용자 에이전트 MUA mail user agent client for composing and reading mail

2. From https://study.example/ap18?unit=dns to a page

All values are reserved synthetic examples.

  1. The browser parses scheme https, host study.example, omitted default port, path /ap18, and query unit=dns.
  2. Browser/OS stub caches are checked, then a recursive resolver is asked. On a miss, it normally makes iterative queries following referrals through root, TLD, and the authoritative server. Recursive and authoritative servers are different roles.
  3. Take receipt of the authoritative answer A=192.0.2.80, TTL=300 as t=0. In a simplified trace with no prefetch or serve-stale, at t=120 the entry is usable with 180 seconds left; after expiry, such as t=301, the resolver queries again. TTL bounds cache freshness; it does not promise instant global propagation.
  4. For HTTP/1.1 or HTTP/2 HTTPS, the order is TCP connection → TLS → HTTP. Typical Web PKI TLS checks certificate name, trust, and validity, authenticates the server, establishes keys, and protects confidentiality and integrity.
  5. Example request:
GET /ap18?unit=dns HTTP/1.1
Host: study.example

The response example has 200 OK, Cache-Control: max-age=600, ETag: "ap18-v1", synthetic Set-Cookie: SID=synth-7f3a; Secure; HttpOnly; SameSite=Lax, and a representation body. 6. Taking receipt as t=0 in a simplified cache, the response is fresh at t=500. At t=700 it is stale, so the client sends If-None-Match: "ap18-v1". A 304 Not Modified tells it to reuse the stored body; it is not a new empty successful representation.

3. DNS roles, caching, and TTL

A stub normally asks a recursive resolver for the final answer. The resolver can cache and, on a miss, follows root/TLD referrals to the zone’s authoritative server. The authoritative server holds zone data. TTL 300 normally limits cache life to 300 seconds, not a worldwide propagation deadline. DNS resolves a name; AP17 IP routing then carries packets toward the address.

4. HTTP messages, status, cookie/session/cache

A request has a method, target, headers, and optional body. A response has a status, headers, and optional body; not every response has a body. GET is intended to be safe and idempotent, but query parameters can appear in URLs and logs and must not contain secrets.

Status Exam-level meaning
200 OK success
301 / 302 permanent / temporary redirect
304 conditional validation; reuse cached body
400 malformed request
401 authentication needed
403 understood but refused
404 not found
500 server fault
503 temporary unavailability

A cookie is client-stored data sent on requests matching its scope. A session is logical state, often server-side and selected by an opaque session ID. An HTTP cache reuses response representations. They are not synonyms. Secure restricts cookie transmission to secure transport, HttpOnly limits script access, and SameSite helps control cross-site sending; none is absolute security.

5. TLS role and limits

Typical HTTPS TLS authenticates the server, establishes keys, and gives transport confidentiality and integrity. A certificate is not the payload-encryption algorithm. TLS does not prove the site’s content or application is trustworthy and does not hide the destination IP. Certificate-chain detail, public-key/signature internals, key exchange, and cipher mathematics are deferred to AP19.

6. Tiny HTTP version comparison

Family Normal HTTPS Web stack (upper → lower layer)
HTTP/1.1 and HTTP/2 HTTP → TLS → TCP
HTTP/3 HTTP semantics → QUIC → UDP

The table lists layers from upper to lower; the actual HTTP/1.1–2 connection sequence is TCP → TLS → HTTP, as shown earlier. QUIC uses UDP as a substrate but supplies reliable streams, congestion control, and integrated TLS. HTTP/3 is neither raw unreliable HTTP nor an additional TCP connection. UDP/443 is common, but a port alone proves neither protocol nor security.

7. Mail communication

The MUA for sender@example.test uses SMTP to a submission server; sender and recipient mail servers relay with SMTP, locating the recipient domain through DNS MX. The message reaches the recipient@example.test mailbox, then POP3 retrieves it or IMAP synchronizes it.

  • SMTP submits/sends/relays; it is not the reading protocol.
  • POP3 is download-oriented and may leave or delete server copies by configuration.
  • IMAP synchronizes server-side mailbox, folders, and state across clients.
  • MIME packages non-ASCII bodies and attachments; it is not a transport protocol.
Use IANA convention
SMTP relay / submission TCP 25 / TCP 587
POP3 / TLS convention TCP 110 / TCP 995
IMAP / TLS convention TCP 143 / TCP 993
HTTP / HTTPS / HTTP/3 TCP 80 / TCP 443 / commonly UDP 443

Registration alone proves neither identity nor security. TLS modes and STARTTLS detail are outside this article.

8. Exam traps

  • Do not reverse recursive and authoritative roles or make the client query every authority recursively.
  • TTL is a cache bound, not a global propagation guarantee.
  • 304 is not a redirect, error, or new empty body; it enables stored-body reuse.
  • 401 means authentication is needed; 403 is refusal despite understanding.
  • Cookie, session, and cache are distinct.
  • HTTPS alone does not establish application trustworthiness.
  • Separate SMTP, POP3/IMAP, and MIME roles.

9. Quick sheet, self-check, and 1/3/7-day review

  • Quick sheet: DNS → (H1/H2: TCP→TLS | H3: QUIC/UDP) → HTTP; SMTP=submit/relay, POP3=retrieve, IMAP=server sync.
  • Self-check: Can you explain recursive vs authoritative, compute t=120/301 and t=500/700, distinguish 304/cookie/session/cache, state TLS limits, and reproduce the mail flow?
  • Day 1: reproduce the URL flow and ten status codes. Day 3: draw both cache timelines and the mail flow. Day 7: retake all questions and explain every distractor.

10. Five original four-choice questions

Q1

Which DNS statement is correct? A. An authoritative server always recursively searches the whole hierarchy for the client. B. A recursive resolver may cache and on a miss follow referrals/query the authoritative hierarchy; the authoritative server holds zone data and TTL bounds normal cache life. C. TTL guarantees worldwide propagation within that time. D. The client must recursively contact every authority from root downward.

Answer: B (2, イ). A reverses the roles. B correctly separates roles and TTL. C invents a propagation guarantee. D ignores the normal stub-to-recursive model.

Q2

Which stack statement is correct? A. HTTP/3 is raw unreliable HTTP directly on UDP. B. TLS runs before DNS. C. The certificate itself is the algorithm encrypting each HTTP body. D. Normal HTTPS HTTP/1.1–2 uses TCP then TLS; HTTP/3 uses QUIC over UDP with reliable streams and integrated TLS, without extra TCP.

Answer: D (4, エ). A ignores QUIC services. B has the order wrong. C confuses certificate and payload cipher. D correctly compares the stacks.

Q3

A stale cached response is validated with If-None-Match, and the validator matches. What can happen? A. 304 permanently redirects. B. 304 reports a server fault. C. The server can return 304 and the client reuses its cached body. D. 304 always includes a new representation body.

Answer: C (3, ウ). A is not its meaning. B is not an error. C is conditional cache reuse. D wrongly requires a new body.

Q4

Which distinction is correct? A. A cookie is client-stored scoped data, a session is logical state often selected by an opaque server-side key, and a cache reuses responses. B. All three are one server file. C. Secure makes cookie theft impossible. D. HttpOnly eliminates every CSRF attack.

Answer: A (1, ア). A separates the roles. B conflates them. C turns a transport restriction into an absolute guarantee. D confuses script access with complete attack prevention.

Q5

Which mail statement is correct? A. POP3 relays between servers and SMTP synchronizes mailboxes. B. IMAP sends mail and SMTP encodes attachments. C. MIME is a mail-server transport. D. SMTP submits/relays, POP3 is download-oriented retrieval, and IMAP synchronizes server-side mailbox state.

Answer: D (4, エ). A reverses roles. B misstates IMAP, SMTP, and MIME. C mistakes packaging for transport. D is correct.

Answer key: [2, 4, 3, 1, 4] = [イ, エ, ウ, ア, エ]

Official sources and notices

First-party sources, checked 2026-10-21: IPA Ver.7.2, RFC 1034, RFC 1035, RFC 9110, RFC 9111, RFC 6265, RFC 8446, RFC 9113, RFC 9114, RFC 9000, RFC 5321, RFC 1939, RFC 9051, RFC 2045, IANA ports.

This independently written study guide is not affiliated with IPA, IETF, or IANA. It uses no past questions or third-party commentary and gives no pass guarantee.

Back to the blog