How to Configure Databricks Network Policy

Published
Length
3 min read

Luis Felipe Dias

All posts

A databricks network policy sets rules for what traffic can enter and leave your workspace. You set it up by naming allowed source addresses and outbound targets at the account level. Teams use these rules to stop data leaks and block bad log in attempts. A strong setup limits both human users and automated jobs to approved paths. Without these bounds, compute nodes might send data to public web hosts. Worse, someone with a stolen key could log in from an unknown home network. How a databrick

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.

A databricks network policy sets rules for what traffic can enter and leave your workspace. You set it up by naming allowed source addresses and outbound targets at the account level.

Teams use these rules to stop data leaks and block bad log in attempts. A strong setup limits both human users and automated jobs to approved paths. Without these bounds, compute nodes might send data to public web hosts. Worse, someone with a stolen key could log in from an unknown home network.

How a databricks network policy works

Network rules in this platform split into two main paths. The first path controls inbound traffic from users and apps to the workspace. Admin teams set up access lists that check the source IP of every request. If a user tries to log in from an unlisted IP, the platform blocks them. You can also use private links so traffic stays inside your cloud network.

The second path controls outbound traffic from serverless compute nodes to outside storage or web hosts. When you apply a databricks network policy to a workspace, compute workloads follow those outbound rules. You can set a restricted mode that blocks all public internet traffic by default. Then, you add allow rules for the specific storage buckets and domains your jobs need.

These policies apply to all principals in the attached workspace. That includes data engineers, analysts, service accounts, and scheduled jobs. A safe default is to deny all outbound paths first. Next, you open only the storage locations required for daily runs. For inbound rules, allow only your corporate VPN range or private cloud network.

How to check rules and find session gaps

Before you enforce a new rule, you should run it in a dry-run mode. This test mode logs blocked traffic without stopping live production jobs. Your team can read the system logs to see which workloads tried to reach outside hosts. If a valid job hits a block, you add its destination to the allow list. Once the logs show no broken jobs, you switch the policy to enforced mode.

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

Continue reading? Get the full guide.

Free. No spam. Unsubscribe anytime.

Checking these logs often is key to keeping your setup safe. You should review denied inbound attempts to spot brute-force attacks or leaked keys. You should also check outbound blocks to find rogue scripts trying to send data out.

Still, network rules only check where traffic comes from and where it goes. They do not inspect what happens inside a valid session. Once a user logs in from an allowed IP, the network rule steps aside. That user can run broad queries and read sensitive tables if their role allows it. A shared service account on an allowed network gives every user the same broad rights. Static network lists also cannot rewrite emails, phone numbers, or card numbers in query results. To control specific queries and mask sensitive fields, teams need controls at the session level.

Govern statements and responses across databases and APIs

Good config and scoped roles are needed setup. They do not check single queries in flight or mask sensitive fields in returned rows. Across Postgres, MySQL, SQL Server, MongoDB, ClickHouse, Kubernetes APIs, SSH, and internal HTTP endpoints, hoop.dev runs beside each supported service as an open-source proxy, a sidecar for your database or API.

First, hoop.dev guardrails block banned queries before they run. Then hoop.dev data masking rewrites matched sensitive values in responses in memory. The audit trail records every statement and verdict per resource. Furthermore, hoop.dev holds SOC 2 Type II and is open source on GitHub.

Frequently asked questions

What is the difference between inbound access lists and outbound network policies?

Inbound access lists control which IP addresses can log in to the workspace control plane. Outbound network policies control where serverless compute workloads can send traffic or read external data.

Can I test a databricks network policy before blocking live jobs?

Yes, you can apply outbound rules in a log-only mode first. This lets you read system logs and find blocked paths before you enforce the rule.

Do network policies mask sensitive data in query results?

No, network rules only allow or block traffic based on IP addresses and domains. They do not inspect SQL queries or rewrite emails and card numbers in results.

The query runs. The emails stay hidden.