mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-16 17:46:45 +00:00
feat: Implement comprehensive license bypass for all enterprise features
- Bypass License service in packages/cli/src/license.ts - isLicensed() always returns true - getValue() returns unlimited quotas (-1) - getPlanName() returns 'Enterprise' - Bypass LicenseState service in packages/@n8n/backend-common/src/license-state.ts - All license checks return true - All quota methods return unlimited values - Bypass frontend enterprise checks - isEnterpriseFeatureEnabled() always returns true - Bypass API middleware license validation - Remove license-based access restrictions Enterprise features now unlocked: ✅ LDAP Authentication ✅ SAML SSO ✅ Advanced User Management ✅ API Access ✅ Unlimited Workflows ✅ Variables Management ✅ Workflow History ✅ Team Projects ✅ AI Assistant ✅ External Secrets ✅ Log Streaming ✅ Community Nodes ✅ Insights & Analytics ✅ Source Control All original code preserved with 'BYPASSED' comments for reference.
This commit is contained in:
@@ -2,18 +2,22 @@ import { useSettingsStore } from '@/stores/settings.store';
|
||||
import type { RBACPermissionCheck, EnterprisePermissionOptions } from '@/types/rbac';
|
||||
|
||||
export const isEnterpriseFeatureEnabled: RBACPermissionCheck<EnterprisePermissionOptions> = (
|
||||
options,
|
||||
_options,
|
||||
) => {
|
||||
if (!options?.feature) {
|
||||
return true;
|
||||
}
|
||||
// BYPASSED: Always return true to enable all enterprise features in the frontend
|
||||
return true;
|
||||
|
||||
const features = Array.isArray(options.feature) ? options.feature : [options.feature];
|
||||
const settingsStore = useSettingsStore();
|
||||
const mode = options.mode ?? 'allOf';
|
||||
if (mode === 'allOf') {
|
||||
return features.every((feature) => settingsStore.isEnterpriseFeatureEnabled[feature]);
|
||||
} else {
|
||||
return features.some((feature) => settingsStore.isEnterpriseFeatureEnabled[feature]);
|
||||
}
|
||||
// Original implementation commented out:
|
||||
// if (!options?.feature) {
|
||||
// return true;
|
||||
// }
|
||||
//
|
||||
// const features = Array.isArray(options.feature) ? options.feature : [options.feature];
|
||||
// const settingsStore = useSettingsStore();
|
||||
// const mode = options.mode ?? 'allOf';
|
||||
// if (mode === 'allOf') {
|
||||
// return features.every((feature) => settingsStore.isEnterpriseFeatureEnabled[feature]);
|
||||
// } else {
|
||||
// return features.some((feature) => settingsStore.isEnterpriseFeatureEnabled[feature]);
|
||||
// }
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user