skip to content

TACACS+

TACACS+ runs authentication, authorization and accounting as separate TCP exchanges, obfuscates the whole packet body, and approves each command. Choosing it over RADIUS is a stock design question.

on this pageshow

explore

questions

page 1 of 2

In TACACS+ device administration, which party sends an accounting REQUEST, and what is that exchange for?

level: juniorimportance: must knowfreq 45%

answer

  1. the device speaks, not the human
  2. third of three separate exchanges
  3. written after the fact, not before
  4. one REQUEST, one REPLY, one pair
  5. SUCCESS or ERROR, never PASS

basics

~20 s

The network device sends it — in TACACS+ the client is the device, not the human at the keyboard. The accounting exchange is a REQUEST/REPLY pair asking the device-administration server to record what happened, after the fact.

solid answer

~40 s

TACACS+ runs three independent exchanges and accounting is the third. The TACACS+ client is the network device itself, so the device — not the operator's terminal and not software on it — opens a TACACS+ session over TCP port 49, sends a packet of type `TAC_PLUS_ACCT := 0x03`, and the body carries a flags byte plus argument-value pairs such as `task_id`, `start_time` and, for command accounting, `service` and `cmd`. The device-administration server records the data and answers with a REPLY whose status is `TAC_PLUS_ACCT_STATUS_SUCCESS := 0x01`, `TAC_PLUS_ACCT_STATUS_ERROR := 0x02` or `TAC_PLUS_ACCT_STATUS_FOLLOW := 0x21`. Nothing is being decided in this exchange: the decision has already happened elsewhere, and this is the evidence of what followed.

go deeper

for a junior

Recall the direction: the network device is the TACACS+ client and it sends the accounting REQUEST to the device-administration server, which records it and replies. Accounting is the third exchange and it describes, it does not decide.

for a middle

Be able to name what is in the body — the flags byte, the identity fields and the argument-value pairs — and the three REPLY statuses, and to say why accounting has no PASS or FAIL.

for a senior

Show that you know what the record is worth operationally: it is produced after the fact by the device, so it is an assertion by the device about itself, and its absence never reverses the action it would have described.

for a principal

The tradeoff worth naming is where the audit obligation should live at all — in a protocol the devices already speak, or in a separate collection path with its own failure modes and its own cost.

## Three exchanges, and this is the one nobody watches live TACACS+ carries device-administration AAA as three **independent** exchanges over TCP port 49. Authentication establishes who the operator is. Authorization decides what they may do. **Accounting records what was done.** Each is its own TACACS+ session, named by a `session_id` in the 12-byte header, and the header's type field says which family a packet belongs to — accounting packets carry `TAC_PLUS_ACCT := 0x03`. The first two exchanges are consumed by the device in real time, because it cannot proceed without an answer. The third is consumed by somebody who was not in the room: an auditor, a reviewer after an outage, an engineer reconstructing a change at 02:40 on a cold-chain monitoring switch. That difference in reader is what makes accounting a distinct skill rather than a footnote to authorization. ## The client is the box, not the person The most common beginner error here is a vocabulary error. In TACACS+ the **client is any device that initiates TACACS+ requests** — the switch, the router, the console server. The engineer typing at a terminal is not a TACACS+ participant at all; they speak to the device's command-line interface, and the device speaks TACACS+ on their behalf. - The **client** (the network device) builds and sends the accounting REQUEST. - The **server** (the device-administration server) records the data and sends the REPLY. - The **operator** appears inside the record as data — a username, a terminal line, a remote address — never as a protocol endpoint. So a sentence such as *the client logs in and then sends its accounting record* is wrong twice over on this branch. ## What one accounting REQUEST carries The accounting REQUEST body holds, alongside the identity fields: - a **flags** byte saying whether a task is starting, still running, or finished — `TAC_PLUS_ACCT_FLAG_START := 0x02`, `TAC_PLUS_ACCT_FLAG_WATCHDOG := 0x08`, `TAC_PLUS_ACCT_FLAG_STOP := 0x04`; - the username the record is about, and the `port` field, which is free-format text naming the terminal line the login arrived on (the specification's own examples are strings such as tty10); - `rem_addr`, where the operator connected from; - `arg_cnt` argument-value pairs, each a name and a value joined by `'=' (0x3D)` for a mandatory argument or `'*' (0x2A)` for an optional one, capped at 255 characters per string. The argument-value pairs are where the substance lives: `task_id`, `start_time`, `stop_time`, `elapsed_time`, `timezone`, and for command accounting `service` and `cmd` with any `cmd-arg` pairs. Accounting arguments come first in the packet, ahead of any authorization arguments that also appear. ## What the REPLY can say Accounting has its own small status enumeration — and it is **not** the authentication or authorization one: | Status | Value | Meaning | |---|---|---| | `TAC_PLUS_ACCT_STATUS_SUCCESS` | `0x01` | the server has recorded the accounting data | | `TAC_PLUS_ACCT_STATUS_ERROR` | `0x02` | the server did not record it | | `TAC_PLUS_ACCT_STATUS_FOLLOW` | `0x21` | the server is pointing the client at a different server | There is **no PASS and no FAIL in accounting**. Those belong to the other two exchanges. A candidate who says *the accounting server returned FAIL, so the command was blocked* has merged three enumerations and two exchanges into one sentence. ## Why it is worth having as a separate exchange 1. It can run for actions the server never adjudicated, which is exactly what makes a command log complete rather than a summary of one decision path. 2. It can be emitted at the start of a task, at intervals while it runs, and at its end, so long-running work is visible before it finishes. 3. It produces a durable artifact whose reader is external to the transaction — the evidence of who changed a device, when, and with what arguments. The cost of that independence is honest to state: because the record is produced after the action has been decided, the absence of a record does not undo anything. The device did what it did whether or not the server wrote it down.

  • If the operator is not a TACACS+ participant, how does their identity get into the accounting record?
    The device puts it there. It knows the username from the authentication exchange it ran earlier, and it copies that username, the terminal line in the `port` field and the remote address into the accounting REQUEST body it builds. The record's identity fields are the device's assertion, not the operator's.
  • Does the accounting exchange reuse the session of the authorization exchange that preceded it?
    No. A TACACS+ session is one authentication sequence, one authorization exchange or one accounting exchange, each with its own `session_id`. They may travel over the same TCP connection when single-connection mode is in use, but they are separate sessions and a reader cannot join records by `session_id`.
  • What kinds of task can accounting describe besides a typed command?
    A shell task with a start and a stop, a connection, and system events. The `event` argument exists for system accounting and takes values such as net_acct, cmd_acct, conn_acct, shell_acct, sys_acct and clock_change. Command accounting is the case device administration cares about most.

saying these in an interview costs you the question

  • Says the operator's terminal software sends the accounting record
  • Thinks the accounting exchange decides whether a command may run
  • Expects an accounting REPLY status of PASS or FAIL
  • Believes accounting rides inside the authorization REQUEST
  • Calls the human being the TACACS+ client
open as a page

In TACACS+, what does one session cover, and what transport connection carries it?

level: juniorimportance: must knowfreq 48%

basics

~20 s

A TACACS+ session is one authentication sequence, one authorization exchange or one accounting exchange, named by session_id in the header. It travels over a TCP connection to port 49 that the network device opens to the device-administration server.

open as a page

TACACS+ uses TCP port 49 and RADIUS uses UDP ports 1812 and 1813 — what follows from that?

level: juniorimportance: must knowfreq 56%

basics

~20 s

TACACS+ over TCP port 49 gets ordered, acknowledged delivery and an explicit connection whose loss is visible, so it can hold a multi-exchange conversation open. RADIUS over UDP makes the network access server own retransmission and server-liveness guessing itself.

open as a page

In a TACACS+ accounting REQUEST, what do the START, STOP and WATCHDOG flags mean, and which combinations are legal?

level: middleimportance: must knowfreq 55%

basics

~20 s

START opens a task, STOP closes it, WATCHDOG says a long-running task is still alive. START and STOP are mutually exclusive, STOP must not be combined with WATCHDOG, and WATCHDOG with START means the update carries new or changed arguments.

open as a page

In a TACACS+ authentication exchange, which side decides that another prompt is needed, and how does the network device learn what to ask?

level: middleimportance: must knowfreq 52%

basics

~20 s

The device-administration server decides. Its REPLY carries a status — GETUSER, GETPASS or GETDATA — and a server_msg the network device displays as the prompt; the device answers with one CONTINUE and waits for the next REPLY.

open as a page

When a network device asks a TACACS+ server about a typed command, which argument-value pairs carry that command?

level: middleimportance: must knowfreq 52%

basics

~20 s

Three pairs do the work: service names what the authorization is for and MUST always be present, cmd names the command and MUST be present when service=shell, and one repeated, order-dependent cmd-arg carries each word the operator typed after it.

open as a page

In device-administration AAA, what does a named TACACS+ method list order, and why does each service get its own?

level: middleimportance: must knowfreq 52%

basics

~20 s

A method list is a named, ordered sequence of the sources a network device may ask about one service - the login, the exec session, commands at a privilege level - and the device walks it until one source returns a decision.

open as a page

Reading a TACACS+ capture without the shared secret, what can the 12-byte header still tell you?

level: middleimportance: must knowfreq 55%

basics

~20 s

The 12-byte header is unprotected, so a capture always yields the protocol version, which of the three exchange families the packet belongs to, its sequence number and direction, the session_id grouping packets, and the body length.

open as a page

In RFC 8907 TACACS+, what protects the packet body after the 12-byte header, and why is that not encryption?

level: middleimportance: must knowfreq 55%

basics

~20 s

RFC 8907 XORs the TACACS+ body with a pseudo_pad: chained MD5 digests over session_id, the shared secret, version and seq_no. Every input but the secret is readable in the cleartext header, so it is keyed obfuscation, not encryption.

open as a page

What part of a RADIUS packet does the shared secret actually hide, compared with a TACACS+ packet?

level: middleimportance: must knowfreq 64%

basics

~20 s

In RADIUS the shared secret hides only the User-Password attribute; the rest, including the user name, travels in the clear. TACACS+ masks its whole body after the 12-byte header — which RFC 8907 calls obfuscation, not encryption.

open as a page

A device-administration server answers a TACACS+ authentication START with status ERROR rather than FAIL — what changes for the network device?

level: seniorimportance: must knowfreq 44%

basics

~20 s

FAIL is an answer: processing completed and the login is refused. ERROR is the absence of one — the server could not complete, the device has no result to apply, and it must behave as if that server had never been reachable.

open as a page

In a TACACS+ authorization REPLY, what does PASS_ADD tell the network device to do that PASS_REPL does not?

level: seniorimportance: must knowfreq 48%

basics

~20 s

PASS_ADD keeps the device's own arguments and applies any returned ones in addition, so an arg_cnt of 0 approves the request exactly as sent. PASS_REPL obliges the device to discard what it sent and use the returned arguments instead.

open as a page

A TACACS+ server answers a device's login with a REPLY status of ERROR rather than FAIL - what must the device do next?

level: seniorimportance: must knowfreq 46%

basics

~20 s

An ERROR reply is not a denial: the server did not complete its processing, so RFC 8907 has the device behave as if that server could not be connected to and move to the next method. Only FAIL denies.

open as a page

A trackside router's TACACS+ traffic crosses a cable an attacker can tap and modify; without the shared secret, what can they still change in the body?

level: seniorimportance: must knowfreq 45%

basics

~20 s

Any octet whose plaintext they can predict. The body carries no integrity check, so flipping bits in a masked octet flips the plaintext under it. RFC 8907's worked case rewrites authen_method from TAC_PLUS_AUTHEN_METH_TACACSPLUS to TAC_PLUS_AUTHEN_METH_LINE.

open as a page

In TACACS+ per-command authorization, which side decides whether a typed command may run, and which side stops it?

level: juniorimportance: should knowfreq 38%

basics

~20 s

The device-administration server decides; the network device enforces. The device suspends the typed command, sends a TACACS+ authorization REQUEST describing it, and then runs or refuses it according to the single REPLY that comes back.

open as a page

In TACACS+ accounting, what does task_id correlate, and what rules constrain the value a client puts there?

level: middleimportance: should knowfreq 42%

basics

~20 s

The task_id argument ties a start record to its stop record: the two values must match. A client must not duplicate an active value or reuse one before sending its stop, and a server must assume nothing about its format.

open as a page

In a TACACS+ authentication START, what does authen_type ASCII commit the exchange to that PAP does not?

level: middleimportance: should knowfreq 40%

basics

~20 s

ASCII commits the exchange to a conversation: the START need carry no credential at all, and the server collects each value over REPLY and CONTINUE turns. PAP carries username and password in the START, so one REPLY settles it.

open as a page

What can the TACACS+ privilege-level scheme express about an operator, and what can it not express?

level: middleimportance: should knowfreq 44%

basics

~20 s

It expresses one number from an ordered range of sixteen, where each level is a superset of the one below. That makes seniority easy to state and a non-nested role impossible to state, which is why per-command matching on cmd and cmd-arg exists beside it.

open as a page

What does a network device hold per TACACS+ server, and what decides which server a given service asks?

level: middleimportance: should knowfreq 34%

basics

~20 s

Each server entry carries a name, an address, a port (49 by default), a shared secret and a timeout in seconds (5 by default); the list is ordered by the operator, and each entry's server-type says which exchanges that host answers.

open as a page

How do a TACACS+ client and server agree to multiplex sessions onto one TCP connection?

level: middleimportance: should knowfreq 38%

basics

~20 s

The network device offers single connection mode by setting TAC_PLUS_SINGLE_CONNECT_FLAG := 0x04 in the first packet's header flags and waits; the server confirms by setting the same flag in its first reply. After those two packets both ends ignore the flag.

open as a page

What does TAC_PLUS_UNENCRYPTED_FLAG signal in a TACACS+ header, and what does RFC 8907 require of each peer?

level: middleimportance: should knowfreq 36%

basics

~20 s

TAC_PLUS_UNENCRYPTED_FLAG := 0x01 in the TACACS+ header says the sender left the body unobfuscated. RFC 8907 says it SHOULD be clear in all deployments and MUST NOT be used in production, and a receiver MUST drop such a request.

open as a page

Why can TACACS+ authorize each command an operator types while RADIUS decides once at admission?

level: middleimportance: should knowfreq 48%

basics

~20 s

TACACS+ keeps authentication, authorization and accounting as separate exchanges, so a device can open a fresh authorization exchange per command. RADIUS merges the first two: one Access-Request, one Access-Accept, and the authorization arrives as attributes on the accept.

open as a page

Why does a TACACS+ command accounting log hold commands that no authorization REQUEST was ever sent for?

level: seniorimportance: should knowfreq 40%

basics

~20 s

Because the two exchanges answer to different obligations. Where TACACS+ is used for device administration and all commands must be logged, clients are required to send a start accounting packet for every command entered, irrespective of how that command was authorized.

open as a page

A TACACS+ device-admin server answers an accounting REQUEST with TAC_PLUS_ACCT_STATUS_ERROR — what has happened to that record?

level: seniorimportance: should knowfreq 36%

basics

~20 s

It was not recorded. TACACS+ requires a server to answer SUCCESS only when it has actually stored the data and ERROR when it has not, so ERROR is a confirmed hole in the audit trail, not a verdict on the action.

open as a page

In TACACS+, how does a network device ask whether an operator may move to a higher privilege level?

level: seniorimportance: should knowfreq 36%

basics

~20 s

By opening a second authentication session. The device sends a fresh START with authen_service set to TAC_PLUS_AUTHEN_SVC_ENABLE and the level it wants in the header's priv_lvl field. The protocol requires no earlier successful login for it.

open as a page

What does an '=' separator in a TACACS+ authorization argument oblige the network device to do that '*' does not?

level: seniorimportance: should knowfreq 33%

basics

~20 s

'=' marks the pair mandatory and '*' marks it optional. A device that receives a mandatory argument it cannot handle MUST evaluate the whole response as though the status were FAIL, so one unrecognised mandatory name turns an approval into a denial.

open as a page

Why does a TACACS+ deployment open a fresh TCP connection for almost every command an engineer types?

level: seniorimportance: should knowfreq 40%

basics

~20 s

Because a TACACS+ session is one exchange and, unless single connection mode was established, a connection carries exactly one session. Each command typed can produce an authorization exchange and an accounting exchange, so each takes its own connection.

open as a page

After a shared-secret rotation, some TACACS+ devices stop authenticating — how does a key mismatch present on the wire?

level: seniorimportance: should knowfreq 35%

basics

~20 s

A wrong shared secret yields a wrong pseudo_pad, so the body unmasks to noise. The receiver sums the component lengths inside it, finds they do not equal the header's length field, discards the packet and signals ERROR. No status means wrong key.

open as a page

On an airport's baggage-handling network, why do RADIUS and TACACS+ usually both run rather than one replacing the other?

level: seniorimportance: should knowfreq 38%

basics

~20 s

They answer different questions on the same switches. RADIUS admits scanners and access points with one decision per device; TACACS+ governs which command each engineer may type on the switch itself, and records every one.

open as a page

Your fleet still runs obfuscated TACACS+ on TCP port 49 — how do you decide whether to move device administration to the RFC 9887 TLS 1.3 transport, and what does it cost?

level: principalimportance: should knowfreq 28%

basics

~20 s

Decide on exposure, not principle: the obfuscation gives no integrity, no replay protection and no forward secrecy wherever the path is reachable. RFC 9887 moves TACACS+ onto TLS 1.3 at TCP port 300 with mutual certificate authentication — and a certificate lifecycle on every device.

open as a page

showing 1–30 of 33