The post has been translated automatically. Original language: Russian
Google released the stable version of Gemini CLI 0.72.0 (December 2) and the preliminary 0.73.0 preview on the same day.2. Both releases are almost entirely devoted to the security of the AI agent in the terminal: the A2A protocol server now requires a token, the OAuth authorization of the MCP servers checks where the addresses came from, and the consent to install the extension covers all their contents, not just the manifest.
a2a-server no longer works without a token
In 0.72.0, the A2A server, through which Gemini CLI accepts tasks from other agents, received a real access check instead of stubs. The token is read once at startup from the GEMINI_IPC_SECRET environment variable, and if it is not present, from CODER_AGENT_AUTH_TOKEN. The behavior is:
- a request without a valid bearer token receives a 401;
- if the token is not set at all, the server responds 500 to any request.;
- the Host and Origin headers must point to the local loop, otherwise 403;
- unauthorized requests are limited to one hundred per minute, further 429;
- The checkpoint's recovery path must remain inside its directory.;
- the isTrusted trust flag from the request body is no longer taken into account.
The developers explicitly marked the change as incompatible: without one of the two variables, the server will not serve a single client.
OAuth for MCP servers checks the source
The change was included in the 0.73.0-preview branch.2. Previously, the client did not verify the issuer field in the authorization metadata with the server it was accessing, as required by RFC 8414. Now the issuer must match the server being polled, the authorization, token issuance, and client registration addresses must have the same origin, and addresses with embedded login and password are rejected. The consent window shows the origin of the authorization point and, if different, the token issuance point. The callback server and dynamic client registration are started only after the user's consent. Configurations where authorizationUrl, tokenUrl, and ClientID are explicitly set on different domains continue to work.
Consent to extensions and commands inside wrappers
In the same preliminary version, consent to install and update the extension takes into account all the contents: hooks, context files, skills, subagents, user commands, policies, and MCP records. Each file is hashed with SHA-256, and the update asks permission again if something has changed, with a list of changes. The dialog now selects "No" by default, meaning pressing Enter cancels the installation.
The policy engine has learned to look inside the wrappers sh -c, env, nice, timeout, cmd.exe and PowerShell: a forbidden command or substitution inside them is now caught the same way as outside. The depth of analysis is limited to five levels, and if exceeded, the command is considered unverifiable. In non-interactive mode with default approval mode, such substitution commands are rejected.
What does this mean in practice?
If you are running a2a-server in CI or in a container, before upgrading to 0.72.0, add GEMINI_IPC_SECRET to the environment secrets, otherwise the integration will start receiving 500. Clients who went to the server through an abandoned port with a different Host will receive a 403 — check the proxy.
With the transition to 0.73, it is worthwhile to run MCP servers from OAuth in advance: self-written servers where tokens are issued by a third-party domain without explicit configuration will stop logging in until you manually register the addresses. In automation scripts that install extensions, do not rely on Enter in the dialog — use the consent flag. And the policy rules, designed to ensure that the sh-c wrapper skips the entire command, will start to work after the update — this is a reason to review them, not weaken them.
The draft text was prepared with the participation of AI, the facts are checked against the original source — official release notes Gemini CLI 0.72.0 and 0.73.0-preview.2 and pull request descriptions in the project repository on GitHub
Google выпустила стабильную версию Gemini CLI 0.72.0 (2 декабря) и в тот же день — предварительную 0.73.0-preview.2. Оба релиза почти целиком посвящены безопасности ИИ-агента в терминале: сервер протокола A2A теперь требует токен, OAuth-авторизация MCP-серверов проверяет, откуда пришли адреса, а согласие на установку расширения охватывает всё их содержимое, а не только манифест.
a2a-server больше не работает без токена
В 0.72.0 сервер A2A, через который Gemini CLI принимает задачи от других агентов, получил настоящую проверку доступа вместо заглушек. Токен читается один раз при старте из переменной окружения GEMINI_IPC_SECRET, а если её нет — из CODER_AGENT_AUTH_TOKEN. Поведение такое:
- запрос без верного bearer-токена получает 401;
- если токен не задан вовсе, сервер отвечает 500 на любой запрос;
- заголовки Host и Origin должны указывать на локальную петлю, иначе 403;
- неавторизованные запросы ограничены сотней в минуту, дальше 429;
- путь восстановления контрольной точки обязан оставаться внутри её каталога;
- флаг доверия isTrusted из тела запроса больше не учитывается.
Разработчики прямо пометили изменение как несовместимое: без одной из двух переменных сервер не обслужит ни одного клиента.
OAuth для MCP-серверов проверяет источник
Изменение вошло в ветку 0.73.0-preview.2. Раньше клиент не сверял поле issuer в метаданных авторизации с сервером, к которому обращался, как того требует RFC 8414. Теперь issuer обязан совпадать с опрашиваемым сервером, адреса авторизации, выдачи токенов и регистрации клиента должны иметь тот же origin, а адреса со встроенными логином и паролем отклоняются. В окне согласия показывается origin точки авторизации и, если отличается, точки выдачи токенов. Колбэк-сервер и динамическая регистрация клиента запускаются только после согласия пользователя. Конфигурации, где явно заданы authorizationUrl, tokenUrl и clientId на разных доменах, продолжают работать.
Согласие на расширения и команды внутри обёрток
В той же предварительной версии согласие на установку и обновление расширения учитывает всё содержимое: хуки, контекстные файлы, навыки, субагентов, пользовательские команды, политики и записи MCP. Каждый файл хешируется SHA-256, и обновление заново спрашивает разрешение, если что-то изменилось, со списком изменений. Диалог теперь по умолчанию выбирает «Нет», то есть нажатие Enter отменяет установку.
Движок политик научился заглядывать внутрь обёрток sh -c, env, nice, timeout, cmd.exe и PowerShell: запрещённая команда или подстановка внутри них теперь ловится так же, как снаружи. Глубина разбора ограничена пятью уровнями, при превышении команда считается непроверяемой. В неинтерактивном режиме с approval-mode default такие команды с подстановкой отклоняются.
Что это значит на практике
Если вы запускаете a2a-server в CI или в контейнере, до обновления на 0.72.0 пропишите GEMINI_IPC_SECRET в секреты окружения, иначе интеграция начнёт получать 500. Клиенты, которые ходили к серверу через проброшенный порт с другим Host, получат 403 — проверьте прокси.
С переходом на 0.73 стоит заранее прогнать MCP-серверы с OAuth: самописные серверы, где токены выдаёт сторонний домен без явной настройки, перестанут авторизоваться, пока не пропишете адреса вручную. В скриптах автоматизации, которые ставят расширения, не полагайтесь на Enter в диалоге — используйте флаг consent. А правила политики, рассчитанные на то, что обёртка sh -c пропускает команду целиком, после обновления начнут срабатывать — это повод пересмотреть их, а не ослаблять.
Черновик текста подготовлен с участием ИИ, факты сверены с первоисточником — официальные release notes Gemini CLI 0.72.0 и 0.73.0-preview.2 и описания pull request в репозитории проекта на GitHub
Comments 1
Newest Popular