Restrict cidr resource

This commit is contained in:
Owen
2026-02-25 14:43:47 -08:00
parent 14cab3fdb8
commit 959f68b520

View File

@@ -310,6 +310,15 @@ export async function signSshKey(
);
}
if (resource.mode == "cidr") {
return next(
createHttpError(
HttpCode.BAD_REQUEST,
"SSHing is not supported for CIDR resources"
)
);
}
// Check if the user has access to the resource
const hasAccess = await canUserAccessSiteResource({
userId: userId,