The Simplest Way to Make Fortigate and Google Pub/Sub Work Like They Should

Published
Length
3 min read

Luis Felipe Dias

All posts

You pair fortigate and google pub/sub to stream firewall events into cloud queues for real-time response. This setup lets security teams route network logs to analytics tools and automated workflows. Network appliances generate huge amounts of traffic data every single second. Sending these events straight to an analysis tool often breaks when traffic spikes. A message queue sits in the middle to absorb those sudden bursts. It holds the firewall records until downstream workers are ready to rea

Your coding agents run with your access.

Claude Code reaches prod with a developer's credentials, and approval prompts get clicked through. hoop.dev checks every query, masks sensitive data, and holds risky changes for a human.

You pair fortigate and google pub/sub to stream firewall events into cloud queues for real-time response. This setup lets security teams route network logs to analytics tools and automated workflows.

Network appliances generate huge amounts of traffic data every single second. Sending these events straight to an analysis tool often breaks when traffic spikes. A message queue sits in the middle to absorb those sudden bursts. It holds the firewall records until downstream workers are ready to read them.

How fortigate and google pub/sub share data and permissions

The firewall starts the flow by catching an event, like a blocked packet or admin login. It formats that event into a structured message and sends it over a secure web request. You can also use a light log collector on a virtual machine to forward older syslog streams. Either way, the event lands on a specific cloud topic built for network logs.

Before the cloud accepts the message, it checks who is sending the data. You set up a dedicated cloud service account just for the firewall or its log collector. You give that account a narrow role that only allows publishing messages to one topic. It cannot read messages, delete topics, or touch other cloud resources in your project.

Once the message reaches the topic, the queue stores it on disk across several zones. Downstream apps use their own separate roles to pull those messages from a subscription. For example, a security tool reads the log to check for known bad IP addresses. At the same time, an archiving job writes the exact same log to cheap cold storage.

Common failure modes and how to scope network paths

Teams often take shortcuts when they first wire up their firewall to a cloud queue. The most common mistake is using a shared service account with broad project permissions. If an attacker steals that key from the appliance, they can read or delete cloud data. You fix this by creating one service account per firewall with publish-only rights.

Another big risk is leaving long-lived static keys on the network device for years. Engineers create a key file, upload it, and forget to rotate it when staff leave. If your setup requires static keys, put them on a strict rotation schedule every few weeks. Even better, run a local forwarder on a cloud host that uses workload identity.

End-to-End Encryption: architecture patterns and best practices

Continue reading? Get the full guide.

Free. No spam. Unsubscribe anytime.

Network paths between the appliance and the cloud API also need tight rules. If you send logs over the public internet, a bad routing rule can drop critical alerts. You should route log traffic through a private tunnel or private cloud interconnect. Set outbound firewall rules so the appliance can only reach the message queue endpoints.

Keeping sensitive data clean in your log streams

Firewall logs and web filter events often carry private user details inside URLs or headers. When those raw strings enter a central message bus, every downstream reader receives a copy. You should strip or rewrite sensitive fields like emails, phone numbers, and card numbers before storage. Data masking rewrites matched fields in results so downstream workers process safe records.

You also need clear audit trails for the humans who manage the firewall and the queue. When an engineer changes a log filter or reads a dead-letter topic, record who did it. Tie every admin session back to your central identity provider instead of using shared admin passwords. Good audit logs tell you who changed a rule and when the change happened.

Check database and API queries on the wire

Identity tools, roles, and network rules decide who opens a session. Setup alone cannot check what each query does or mask sensitive values in a response once a session starts. When workflows touch Postgres, MySQL, SQL Server, MongoDB, ClickHouse, Kubernetes APIs, SSH, or internal HTTP APIs, hoop.dev runs beside those services as an open-source proxy, a sidecar for your Postgres or API. It inspects requests coming in and results going back on the wire.

Your login details and client tools stay as they are while hoop.dev guardrails refuse bad deletes or drops before they run. On responses, hoop.dev data masking rewrites matched sensitive values in memory. Furthermore, hoop.dev holds SOC 2 Type II, is MIT licensed, and writes every query and decision to an audit trail that generates evidence for HIPAA, GDPR, and PCI DSS. See the source on GitHub.

Frequently asked questions

Can the firewall send logs straight to the cloud queue?

Yes, modern appliances can push event hooks over HTTPS to cloud endpoints. For high-volume traffic logs, many teams run a small collector VM to batch the messages first.

What role does the firewall service account need?

Give the service account only the publisher role on the single target topic. Never grant project editor, owner, or subscriber roles to the identity that sends logs.

How do we handle traffic spikes without dropping firewall logs?

Enable local disk queuing on your log forwarder and set retry rules for failed web requests. The cloud message bus scales on its own to absorb sudden bursts once packets arrive.

The query runs. The emails stay hidden.