mirror of
https://github.com/awatertrevi/infisical.git
synced 2026-10-11 05:28:51 +00:00
Patch integrations Secret querying by workspaceId
This commit is contained in:
@@ -65,7 +65,6 @@ export const createAPIKeyData = async (req: Request, res: Response) => {
|
||||
apiKey = `ak.${apiKeyData._id.toString()}.${secret}`;
|
||||
|
||||
} catch (err) {
|
||||
console.error(err);
|
||||
Sentry.setUser({ email: req.user.email });
|
||||
Sentry.captureException(err);
|
||||
return res.status(400).send({
|
||||
|
||||
@@ -72,7 +72,7 @@ const getSecretsHelper = async ({
|
||||
try {
|
||||
const key = await getKey({ workspaceId });
|
||||
const secrets = await Secret.find({
|
||||
workspaceId,
|
||||
workspace: workspaceId,
|
||||
environment,
|
||||
type: SECRET_SHARED
|
||||
});
|
||||
@@ -84,7 +84,7 @@ const getSecretsHelper = async ({
|
||||
tag: secret.secretKeyTag,
|
||||
key
|
||||
});
|
||||
|
||||
|
||||
const secretValue = decryptSymmetric({
|
||||
ciphertext: secret.secretValueCiphertext,
|
||||
iv: secret.secretValueIV,
|
||||
|
||||
@@ -55,7 +55,6 @@ const validateSecrets = async ({
|
||||
});
|
||||
|
||||
} catch (err) {
|
||||
console.error(err);
|
||||
throw new Error('Failed to validate secrets');
|
||||
}
|
||||
|
||||
|
||||
@@ -48,7 +48,7 @@ const INTEGRATION_OPTIONS = [
|
||||
name: 'Vercel',
|
||||
slug: 'vercel',
|
||||
image: 'Vercel',
|
||||
isAvailable: false,
|
||||
isAvailable: true,
|
||||
type: 'vercel',
|
||||
clientId: '',
|
||||
clientSlug: CLIENT_SLUG_VERCEL,
|
||||
@@ -58,7 +58,7 @@ const INTEGRATION_OPTIONS = [
|
||||
name: 'Netlify',
|
||||
slug: 'netlify',
|
||||
image: 'Netlify',
|
||||
isAvailable: false,
|
||||
isAvailable: true,
|
||||
type: 'oauth2',
|
||||
clientId: CLIENT_ID_NETLIFY,
|
||||
docsLink: ''
|
||||
@@ -67,7 +67,7 @@ const INTEGRATION_OPTIONS = [
|
||||
name: 'GitHub',
|
||||
slug: 'github',
|
||||
image: 'GitHub',
|
||||
isAvailable: false,
|
||||
isAvailable: true,
|
||||
type: 'oauth2',
|
||||
clientId: CLIENT_ID_GITHUB,
|
||||
docsLink: ''
|
||||
|
||||
Reference in New Issue
Block a user