Skip to content

Instantly share code, notes, and snippets.

@shuckc
Created March 12, 2025 15:05
Show Gist options
  • Save shuckc/97373cdb4083df4e88447c9fddc28d20 to your computer and use it in GitHub Desktop.
Save shuckc/97373cdb4083df4e88447c9fddc28d20 to your computer and use it in GitHub Desktop.
KDB limit webapp to select existing tables
/ patch HTTP GET/POST handler to not run arbitary Q code from the url
/ this is the minimal handler to keep the built-in UI functional. It evaluates queries
/ that only match whole tables and global variables from the root namespace
.h.val:{-2 .Q.s1 x;$[x in (string each tables `.),string each system "v";:value x;'protect]}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment