diff options
author | Alexander Kurtakov | 2021-02-12 13:46:45 +0000 |
---|---|---|
committer | Alexander Kurtakov | 2021-02-12 16:58:39 +0000 |
commit | bf10fa2c4bb325538bc1b4c38feac896640b2fd4 (patch) | |
tree | 7e21f0f67e67cfa4f0db4d92f11f7d863c890086 | |
parent | c3b9eb8e235a6e3dc784661b64ec1b32d259c38d (diff) | |
download | rt.equinox.bundles-I20210212-1840.tar.gz rt.equinox.bundles-I20210212-1840.tar.xz rt.equinox.bundles-I20210212-1840.zip |
Remove win32.x86 security fragment.Y20210222-1000Y20210221-1000Y20210220-1000Y20210219-1000Y20210218-1000Y20210217-1000Y20210216-1000Y20210215-1020Y20210214-1000Y20210213-1200S4_19_0_M3I20210222-1800I20210222-0600I20210221-1800I20210221-0600I20210220-1800I20210220-0600I20210219-1800I20210219-0300I20210217-1800I20210217-0600I20210216-2020I20210216-1800I20210216-1340I20210216-1140I20210216-1030I20210216-0600I20210215-1800I20210215-0700I20210215-0600I20210214-1800I20210214-0600I20210213-1800I20210213-0600I20210212-1840
Not being built for multiple releases but still gets multiple edits per
release from mass changes.
Change-Id: I29220e5544d03bd7953da19c60c046cfc7b76e4d
Signed-off-by: Alexander Kurtakov <akurtako@redhat.com>
19 files changed, 0 insertions, 871 deletions
diff --git a/bundles/org.eclipse.equinox.security.win32.x86/.classpath b/bundles/org.eclipse.equinox.security.win32.x86/.classpath deleted file mode 100644 index eca7bdba8..000000000 --- a/bundles/org.eclipse.equinox.security.win32.x86/.classpath +++ /dev/null @@ -1,7 +0,0 @@ -<?xml version="1.0" encoding="UTF-8"?> -<classpath> - <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.8"/> - <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/> - <classpathentry kind="src" path="src"/> - <classpathentry kind="output" path="bin"/> -</classpath> diff --git a/bundles/org.eclipse.equinox.security.win32.x86/.project b/bundles/org.eclipse.equinox.security.win32.x86/.project deleted file mode 100644 index 4ba0fa06e..000000000 --- a/bundles/org.eclipse.equinox.security.win32.x86/.project +++ /dev/null @@ -1,34 +0,0 @@ -<?xml version="1.0" encoding="UTF-8"?> -<projectDescription> - <name>org.eclipse.equinox.security.win32.x86</name> - <comment></comment> - <projects> - </projects> - <buildSpec> - <buildCommand> - <name>org.eclipse.jdt.core.javabuilder</name> - <arguments> - </arguments> - </buildCommand> - <buildCommand> - <name>org.eclipse.pde.ManifestBuilder</name> - <arguments> - </arguments> - </buildCommand> - <buildCommand> - <name>org.eclipse.pde.SchemaBuilder</name> - <arguments> - </arguments> - </buildCommand> - <buildCommand> - <name>org.eclipse.pde.api.tools.apiAnalysisBuilder</name> - <arguments> - </arguments> - </buildCommand> - </buildSpec> - <natures> - <nature>org.eclipse.pde.PluginNature</nature> - <nature>org.eclipse.jdt.core.javanature</nature> - <nature>org.eclipse.pde.api.tools.apiAnalysisNature</nature> - </natures> -</projectDescription> diff --git a/bundles/org.eclipse.equinox.security.win32.x86/.settings/org.eclipse.core.runtime.prefs b/bundles/org.eclipse.equinox.security.win32.x86/.settings/org.eclipse.core.runtime.prefs deleted file mode 100644 index 5a0ad22d2..000000000 --- a/bundles/org.eclipse.equinox.security.win32.x86/.settings/org.eclipse.core.runtime.prefs +++ /dev/null @@ -1,2 +0,0 @@ -eclipse.preferences.version=1 -line.separator=\n diff --git a/bundles/org.eclipse.equinox.security.win32.x86/.settings/org.eclipse.jdt.core.prefs b/bundles/org.eclipse.equinox.security.win32.x86/.settings/org.eclipse.jdt.core.prefs deleted file mode 100644 index aaca2d694..000000000 --- a/bundles/org.eclipse.equinox.security.win32.x86/.settings/org.eclipse.jdt.core.prefs +++ /dev/null @@ -1,106 +0,0 @@ -eclipse.preferences.version=1 -org.eclipse.jdt.core.compiler.annotation.inheritNullAnnotations=disabled -org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=ignore -org.eclipse.jdt.core.compiler.annotation.nonnull=org.eclipse.jdt.annotation.NonNull -org.eclipse.jdt.core.compiler.annotation.nonnull.secondary= -org.eclipse.jdt.core.compiler.annotation.nonnullbydefault=org.eclipse.jdt.annotation.NonNullByDefault -org.eclipse.jdt.core.compiler.annotation.nonnullbydefault.secondary= -org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nullable -org.eclipse.jdt.core.compiler.annotation.nullable.secondary= -org.eclipse.jdt.core.compiler.annotation.nullanalysis=disabled -org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled -org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.8 -org.eclipse.jdt.core.compiler.compliance=1.8 -org.eclipse.jdt.core.compiler.problem.APILeak=warning -org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=warning -org.eclipse.jdt.core.compiler.problem.assertIdentifier=error -org.eclipse.jdt.core.compiler.problem.autoboxing=ignore -org.eclipse.jdt.core.compiler.problem.comparingIdentical=warning -org.eclipse.jdt.core.compiler.problem.deadCode=warning -org.eclipse.jdt.core.compiler.problem.deprecation=warning -org.eclipse.jdt.core.compiler.problem.deprecationInDeprecatedCode=disabled -org.eclipse.jdt.core.compiler.problem.deprecationWhenOverridingDeprecatedMethod=disabled -org.eclipse.jdt.core.compiler.problem.discouragedReference=warning -org.eclipse.jdt.core.compiler.problem.emptyStatement=ignore -org.eclipse.jdt.core.compiler.problem.enumIdentifier=error -org.eclipse.jdt.core.compiler.problem.explicitlyClosedAutoCloseable=warning -org.eclipse.jdt.core.compiler.problem.fallthroughCase=ignore -org.eclipse.jdt.core.compiler.problem.fatalOptionalError=disabled -org.eclipse.jdt.core.compiler.problem.fieldHiding=ignore -org.eclipse.jdt.core.compiler.problem.finalParameterBound=warning -org.eclipse.jdt.core.compiler.problem.finallyBlockNotCompletingNormally=warning -org.eclipse.jdt.core.compiler.problem.forbiddenReference=error -org.eclipse.jdt.core.compiler.problem.hiddenCatchBlock=warning -org.eclipse.jdt.core.compiler.problem.includeNullInfoFromAsserts=disabled -org.eclipse.jdt.core.compiler.problem.incompatibleNonInheritedInterfaceMethod=warning -org.eclipse.jdt.core.compiler.problem.incompleteEnumSwitch=warning -org.eclipse.jdt.core.compiler.problem.indirectStaticAccess=warning -org.eclipse.jdt.core.compiler.problem.localVariableHiding=ignore -org.eclipse.jdt.core.compiler.problem.methodWithConstructorName=warning -org.eclipse.jdt.core.compiler.problem.missingDefaultCase=ignore -org.eclipse.jdt.core.compiler.problem.missingDeprecatedAnnotation=warning -org.eclipse.jdt.core.compiler.problem.missingEnumCaseDespiteDefault=disabled -org.eclipse.jdt.core.compiler.problem.missingHashCodeMethod=ignore -org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotation=warning -org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotationForInterfaceMethodImplementation=enabled -org.eclipse.jdt.core.compiler.problem.missingSerialVersion=warning -org.eclipse.jdt.core.compiler.problem.missingSynchronizedOnInheritedMethod=ignore -org.eclipse.jdt.core.compiler.problem.noEffectAssignment=warning -org.eclipse.jdt.core.compiler.problem.noImplicitStringConversion=warning -org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=ignore -org.eclipse.jdt.core.compiler.problem.nonnullParameterAnnotationDropped=warning -org.eclipse.jdt.core.compiler.problem.nonnullTypeVariableFromLegacyInvocation=warning -org.eclipse.jdt.core.compiler.problem.nullAnnotationInferenceConflict=error -org.eclipse.jdt.core.compiler.problem.nullReference=warning -org.eclipse.jdt.core.compiler.problem.nullSpecViolation=error -org.eclipse.jdt.core.compiler.problem.nullUncheckedConversion=warning -org.eclipse.jdt.core.compiler.problem.overridingPackageDefaultMethod=warning -org.eclipse.jdt.core.compiler.problem.parameterAssignment=ignore -org.eclipse.jdt.core.compiler.problem.pessimisticNullAnalysisForFreeTypeVariables=warning -org.eclipse.jdt.core.compiler.problem.possibleAccidentalBooleanAssignment=ignore -org.eclipse.jdt.core.compiler.problem.potentialNullReference=ignore -org.eclipse.jdt.core.compiler.problem.potentiallyUnclosedCloseable=ignore -org.eclipse.jdt.core.compiler.problem.rawTypeReference=warning -org.eclipse.jdt.core.compiler.problem.redundantNullAnnotation=warning -org.eclipse.jdt.core.compiler.problem.redundantNullCheck=ignore -org.eclipse.jdt.core.compiler.problem.redundantSpecificationOfTypeArguments=warning -org.eclipse.jdt.core.compiler.problem.redundantSuperinterface=warning -org.eclipse.jdt.core.compiler.problem.reportMethodCanBePotentiallyStatic=ignore -org.eclipse.jdt.core.compiler.problem.reportMethodCanBeStatic=ignore -org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled -org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=warning -org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=disabled -org.eclipse.jdt.core.compiler.problem.suppressWarnings=enabled -org.eclipse.jdt.core.compiler.problem.syntacticNullAnalysisForFields=disabled -org.eclipse.jdt.core.compiler.problem.syntheticAccessEmulation=ignore -org.eclipse.jdt.core.compiler.problem.terminalDeprecation=warning -org.eclipse.jdt.core.compiler.problem.typeParameterHiding=warning -org.eclipse.jdt.core.compiler.problem.unavoidableGenericTypeProblems=enabled -org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=warning -org.eclipse.jdt.core.compiler.problem.unclosedCloseable=warning -org.eclipse.jdt.core.compiler.problem.undocumentedEmptyBlock=ignore -org.eclipse.jdt.core.compiler.problem.unhandledWarningToken=warning -org.eclipse.jdt.core.compiler.problem.unlikelyCollectionMethodArgumentType=warning -org.eclipse.jdt.core.compiler.problem.unlikelyCollectionMethodArgumentTypeStrict=disabled -org.eclipse.jdt.core.compiler.problem.unlikelyEqualsArgumentType=info -org.eclipse.jdt.core.compiler.problem.unnecessaryElse=ignore -org.eclipse.jdt.core.compiler.problem.unnecessaryTypeCheck=warning -org.eclipse.jdt.core.compiler.problem.unqualifiedFieldAccess=ignore -org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownException=ignore -org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionExemptExceptionAndThrowable=enabled -org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionIncludeDocCommentReference=enabled -org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionWhenOverriding=disabled -org.eclipse.jdt.core.compiler.problem.unusedExceptionParameter=ignore -org.eclipse.jdt.core.compiler.problem.unusedImport=warning -org.eclipse.jdt.core.compiler.problem.unusedLabel=warning -org.eclipse.jdt.core.compiler.problem.unusedLocal=warning -org.eclipse.jdt.core.compiler.problem.unusedObjectAllocation=ignore -org.eclipse.jdt.core.compiler.problem.unusedParameter=ignore -org.eclipse.jdt.core.compiler.problem.unusedParameterIncludeDocCommentReference=enabled -org.eclipse.jdt.core.compiler.problem.unusedParameterWhenImplementingAbstract=disabled -org.eclipse.jdt.core.compiler.problem.unusedParameterWhenOverridingConcrete=disabled -org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=warning -org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=ignore -org.eclipse.jdt.core.compiler.problem.unusedWarningToken=warning -org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=warning -org.eclipse.jdt.core.compiler.source=1.8 diff --git a/bundles/org.eclipse.equinox.security.win32.x86/META-INF/MANIFEST.MF b/bundles/org.eclipse.equinox.security.win32.x86/META-INF/MANIFEST.MF deleted file mode 100644 index bb81d1a46..000000000 --- a/bundles/org.eclipse.equinox.security.win32.x86/META-INF/MANIFEST.MF +++ /dev/null @@ -1,12 +0,0 @@ -Manifest-Version: 1.0 -Bundle-ManifestVersion: 2 -Bundle-Name: %fragmentName -Bundle-SymbolicName: org.eclipse.equinox.security.win32.x86;singleton:=true -Bundle-Version: 1.1.100.qualifier -Bundle-Vendor: %providerName -Fragment-Host: org.eclipse.equinox.security;bundle-version="[1.0.0,2.0.0)" -Bundle-RequiredExecutionEnvironment: JavaSE-1.8 -Bundle-Localization: fragment -Eclipse-PlatformFilter: (& (osgi.os=win32) (osgi.arch=x86)) -Export-Package: org.eclipse.equinox.internal.security.win32;x-internal:=true -Automatic-Module-Name: org.eclipse.equinox.security.win32.x86 diff --git a/bundles/org.eclipse.equinox.security.win32.x86/about.html b/bundles/org.eclipse.equinox.security.win32.x86/about.html deleted file mode 100644 index 164f781a8..000000000 --- a/bundles/org.eclipse.equinox.security.win32.x86/about.html +++ /dev/null @@ -1,36 +0,0 @@ -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" - "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml"> -<head> -<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" /> -<title>About</title> -</head> -<body lang="EN-US"> - <h2>About This Content</h2> - - <p>November 30, 2017</p> - <h3>License</h3> - - <p> - The Eclipse Foundation makes available all content in this plug-in - ("Content"). Unless otherwise indicated below, the Content - is provided to you under the terms and conditions of the Eclipse - Public License Version 2.0 ("EPL"). A copy of the EPL is - available at <a href="http://www.eclipse.org/legal/epl-2.0">http://www.eclipse.org/legal/epl-2.0</a>. - For purposes of the EPL, "Program" will mean the Content. - </p> - - <p> - If you did not receive this Content directly from the Eclipse - Foundation, the Content is being redistributed by another party - ("Redistributor") and different terms and conditions may - apply to your use of any object code in the Content. Check the - Redistributor's license that was provided with the Content. If no such - license exists, contact the Redistributor. Unless otherwise indicated - below, the terms and conditions of the EPL still apply to any source - code in the Content and such source code may be obtained at <a - href="http://www.eclipse.org/">http://www.eclipse.org</a>. - </p> - -</body> -</html>
\ No newline at end of file diff --git a/bundles/org.eclipse.equinox.security.win32.x86/build.properties b/bundles/org.eclipse.equinox.security.win32.x86/build.properties deleted file mode 100644 index fde2496c0..000000000 --- a/bundles/org.eclipse.equinox.security.win32.x86/build.properties +++ /dev/null @@ -1,24 +0,0 @@ -############################################################################### -# Copyright (c) 2005, 2008 IBM Corporation and others. -# -# This program and the accompanying materials -# are made available under the terms of the Eclipse Public License 2.0 -# which accompanies this distribution, and is available at -# https://www.eclipse.org/legal/epl-2.0/ -# -# SPDX-License-Identifier: EPL-2.0 -# -# Contributors: -# IBM Corporation - initial API and implementation -############################################################################### -source.. = src/ -output.. = bin/ -bin.includes = META-INF/,\ - .,\ - fragment.properties,\ - fragment.xml,\ - about.html,\ - jnicrypt.dll -src.includes = cpp/,\ - META-INF/,\ - about.html diff --git a/bundles/org.eclipse.equinox.security.win32.x86/cpp/ReadMe.txt b/bundles/org.eclipse.equinox.security.win32.x86/cpp/ReadMe.txt deleted file mode 100644 index aff487da0..000000000 --- a/bundles/org.eclipse.equinox.security.win32.x86/cpp/ReadMe.txt +++ /dev/null @@ -1,47 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2007, 2008 IBM Corporation and others. - * - * This program and the accompanying materials - * are made available under the terms of the Eclipse Public License 2.0 - * which accompanies this distribution, and is available at - * https://www.eclipse.org/legal/epl-2.0/ - * - * SPDX-License-Identifier: EPL-2.0 - * - * Contributors: - * IBM Corporation - initial API and implementation - *******************************************************************************/ - -This is a JNI bridge to access native Windows encryption methods from Java. The methods -perform user-specific encryption of the data. The same user can later decrypt data using -methods provided by this DLL. A different user won't be able to decrypt the data. - -If the user has a roaming profile, he can decrypt data on a different computer in the domain. - -In the event if stand-alone computer needs to have OS re-installed (or the domain controller -and the computer in the domain), be sure to create Windows password recovery disk BEFORE -re-installing the operating system. - -Note that this mechanism is intended to be used with small size data (i.e., passwords). For -large amount of data consider encrypting your password using this mechanism and using -symmetric encryption to encrypt the data. - -To compile this DLL: -=> JAVA_HOME environment variable needs to be setup so that jni.h can be found - -Note C++ projects settings: -=> Additional include directories - "$(JAVA_HOME)/include";"$(JAVA_HOME)/include/win32" -=> Additional linker dependency - Crypt32.lib - -ON THE SUBJECT OF RUNTIME LIBRARY - -The original DLL was build using Visual Studio 2005. That introduced dependency on -the msvcr80.dll that might be missing in some Windows installations. - -The msvcr80.dll is available as a part of the "Microsoft Visual C++ 2005 SP1 Redistributable Package": -http://www.microsoft.com/downloads/details.aspx?FamilyID=200B2FD9-AE1A-4A14-984D-389C36F85647&displaylang=en - -In order to replace dependency on msvcr80.dll with the dependency on msvcrt.dll the DLL currently -included in this fragment was recompiled with Visual Studio 6.0 using wincrypt.h and crypt32.lib -from the Visual Studio 2005. - diff --git a/bundles/org.eclipse.equinox.security.win32.x86/cpp/jnicrypt.cpp b/bundles/org.eclipse.equinox.security.win32.x86/cpp/jnicrypt.cpp deleted file mode 100644 index d1ad79c23..000000000 --- a/bundles/org.eclipse.equinox.security.win32.x86/cpp/jnicrypt.cpp +++ /dev/null @@ -1,84 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2007, 2008 IBM Corporation and others. - * - * This program and the accompanying materials - * are made available under the terms of the Eclipse Public License 2.0 - * which accompanies this distribution, and is available at - * https://www.eclipse.org/legal/epl-2.0/ - * - * SPDX-License-Identifier: EPL-2.0 - * - * Contributors: - * IBM Corporation - initial API and implementation - *******************************************************************************/ - -#define WIN32_LEAN_AND_MEAN // Exclude rarely-used stuff from Windows headers - -#include <windows.h> -#include <wincrypt.h> -#include "jnicrypt.h" - -BOOL APIENTRY DllMain(HMODULE hModule, DWORD ul_reason_for_call, LPVOID lpReserved) -{ - return TRUE; -} - -JNIEXPORT jbyteArray JNICALL Java_org_eclipse_equinox_internal_security_win32_WinCrypto_winencrypt - (JNIEnv *env, jobject obj, jbyteArray value) -{ - jsize size = env->GetArrayLength(value); - jbyte *body = env->GetByteArrayElements(value, NULL); - if (body == NULL) - return NULL; - - DATA_BLOB clearText; - DATA_BLOB encryptedText; - clearText.pbData = (BYTE*) body; - clearText.cbData = (DWORD) size; - - BOOL result = CryptProtectData(&clearText, L"Equinox", NULL, NULL, NULL, 0, &encryptedText); - - // release memory allocated by Java environment - env->ReleaseByteArrayElements(value, body, 0); - - if (result == FALSE) - return NULL; - - jbyteArray returnArray = env->NewByteArray(encryptedText.cbData); - env->SetByteArrayRegion(returnArray, 0, encryptedText.cbData, (jbyte*) encryptedText.pbData); - LocalFree(encryptedText.pbData); // no need any more, have Java representation - - return returnArray; -} - -JNIEXPORT jbyteArray JNICALL Java_org_eclipse_equinox_internal_security_win32_WinCrypto_windecrypt - (JNIEnv *env, jobject obj, jbyteArray value) -{ - jsize size = env->GetArrayLength(value); - jbyte *body = env->GetByteArrayElements(value, NULL); - if (body == NULL) - return NULL; - - DATA_BLOB clearText; - DATA_BLOB encryptedText; - encryptedText.pbData = (BYTE*) body; - encryptedText.cbData = (DWORD) size; - - LPWSTR pDescrOut = NULL; - BOOL result = CryptUnprotectData(&encryptedText, &pDescrOut, NULL, NULL, NULL, 0, &clearText); - - if (pDescrOut != NULL) - LocalFree(pDescrOut); - - // release memory allocated by Java environment - env->ReleaseByteArrayElements(value, body, 0); - - if (result == FALSE) - return NULL; - - jbyteArray returnArray = env->NewByteArray(clearText.cbData); - env->SetByteArrayRegion(returnArray, 0, clearText.cbData, (jbyte*) clearText.pbData); - LocalFree(clearText.pbData); // no need any more, have Java representation - - return returnArray; -} diff --git a/bundles/org.eclipse.equinox.security.win32.x86/cpp/jnicrypt.h b/bundles/org.eclipse.equinox.security.win32.x86/cpp/jnicrypt.h deleted file mode 100644 index a5da0a151..000000000 --- a/bundles/org.eclipse.equinox.security.win32.x86/cpp/jnicrypt.h +++ /dev/null @@ -1,31 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2007, 2008 IBM Corporation and others. - * - * This program and the accompanying materials - * are made available under the terms of the Eclipse Public License 2.0 - * which accompanies this distribution, and is available at - * https://www.eclipse.org/legal/epl-2.0/ - * - * SPDX-License-Identifier: EPL-2.0 - * - * Contributors: - * IBM Corporation - initial API and implementation - *******************************************************************************/ -#include <jni.h> - -#ifndef EQUINOX_WIN32_CRYPTO -#define EQUINOX_WIN32_CRYPTO - -#ifdef __cplusplus -extern "C" { -#endif - -JNIEXPORT jbyteArray JNICALL Java_org_eclipse_equinox_internal_security_win32_WinCrypto_windecrypt(JNIEnv *, jobject, jbyteArray); -JNIEXPORT jbyteArray JNICALL Java_org_eclipse_equinox_internal_security_win32_WinCrypto_winencrypt(JNIEnv *, jobject, jbyteArray); - -#ifdef __cplusplus -} -#endif - -#endif // #ifndef EQUINOX_WIN32_CRYPTO - diff --git a/bundles/org.eclipse.equinox.security.win32.x86/cpp/jnicrypt.vcproj b/bundles/org.eclipse.equinox.security.win32.x86/cpp/jnicrypt.vcproj deleted file mode 100644 index c207c57a9..000000000 --- a/bundles/org.eclipse.equinox.security.win32.x86/cpp/jnicrypt.vcproj +++ /dev/null @@ -1,209 +0,0 @@ -<?xml version="1.0" encoding="Windows-1252"?> -<VisualStudioProject - ProjectType="Visual C++" - Version="8.00" - Name="jnicrypt" - ProjectGUID="{F34C755E-2053-4783-85FC-356BC2CE2A35}" - RootNamespace="jnicrypt" - Keyword="Win32Proj" - > - <Platforms> - <Platform - Name="Win32" - /> - </Platforms> - <ToolFiles> - </ToolFiles> - <Configurations> - <Configuration - Name="Debug|Win32" - OutputDirectory="$(SolutionDir)$(ConfigurationName)" - IntermediateDirectory="$(ConfigurationName)" - ConfigurationType="2" - CharacterSet="1" - > - <Tool - Name="VCPreBuildEventTool" - /> - <Tool - Name="VCCustomBuildTool" - /> - <Tool - Name="VCXMLDataGeneratorTool" - /> - <Tool - Name="VCWebServiceProxyGeneratorTool" - /> - <Tool - Name="VCMIDLTool" - /> - <Tool - Name="VCCLCompilerTool" - Optimization="0" - AdditionalIncludeDirectories=""$(JAVA_HOME)/include";"$(JAVA_HOME)/include/win32"" - PreprocessorDefinitions="WIN32;_DEBUG;_WINDOWS;_USRDLL;JNICRYPT_EXPORTS" - MinimalRebuild="true" - BasicRuntimeChecks="3" - RuntimeLibrary="3" - UsePrecompiledHeader="0" - WarningLevel="3" - Detect64BitPortabilityProblems="true" - DebugInformationFormat="4" - /> - <Tool - Name="VCManagedResourceCompilerTool" - /> - <Tool - Name="VCResourceCompilerTool" - /> - <Tool - Name="VCPreLinkEventTool" - /> - <Tool - Name="VCLinkerTool" - AdditionalDependencies="Crypt32.lib" - LinkIncremental="2" - GenerateDebugInformation="true" - SubSystem="2" - TargetMachine="1" - /> - <Tool - Name="VCALinkTool" - /> - <Tool - Name="VCManifestTool" - /> - <Tool - Name="VCXDCMakeTool" - /> - <Tool - Name="VCBscMakeTool" - /> - <Tool - Name="VCFxCopTool" - /> - <Tool - Name="VCAppVerifierTool" - /> - <Tool - Name="VCWebDeploymentTool" - /> - <Tool - Name="VCPostBuildEventTool" - /> - </Configuration> - <Configuration - Name="Release|Win32" - OutputDirectory="$(SolutionDir)$(ConfigurationName)" - IntermediateDirectory="$(ConfigurationName)" - ConfigurationType="2" - CharacterSet="1" - WholeProgramOptimization="1" - > - <Tool - Name="VCPreBuildEventTool" - /> - <Tool - Name="VCCustomBuildTool" - /> - <Tool - Name="VCXMLDataGeneratorTool" - /> - <Tool - Name="VCWebServiceProxyGeneratorTool" - /> - <Tool - Name="VCMIDLTool" - /> - <Tool - Name="VCCLCompilerTool" - AdditionalIncludeDirectories=""$(JAVA_HOME)/include";"$(JAVA_HOME)/include/win32"" - PreprocessorDefinitions="WIN32;NDEBUG;_WINDOWS;_USRDLL;JNICRYPT_EXPORTS" - RuntimeLibrary="2" - UsePrecompiledHeader="0" - WarningLevel="3" - Detect64BitPortabilityProblems="true" - DebugInformationFormat="3" - /> - <Tool - Name="VCManagedResourceCompilerTool" - /> - <Tool - Name="VCResourceCompilerTool" - /> - <Tool - Name="VCPreLinkEventTool" - /> - <Tool - Name="VCLinkerTool" - AdditionalDependencies="Crypt32.lib" - LinkIncremental="1" - GenerateDebugInformation="true" - SubSystem="2" - OptimizeReferences="2" - EnableCOMDATFolding="2" - TargetMachine="1" - /> - <Tool - Name="VCALinkTool" - /> - <Tool - Name="VCManifestTool" - /> - <Tool - Name="VCXDCMakeTool" - /> - <Tool - Name="VCBscMakeTool" - /> - <Tool - Name="VCFxCopTool" - /> - <Tool - Name="VCAppVerifierTool" - /> - <Tool - Name="VCWebDeploymentTool" - /> - <Tool - Name="VCPostBuildEventTool" - /> - </Configuration> - </Configurations> - <References> - </References> - <Files> - <Filter - Name="Source Files" - Filter="cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx" - UniqueIdentifier="{4FC737F1-C7A5-4376-A066-2A32D752A2FF}" - > - <File - RelativePath=".\jnicrypt.cpp" - > - </File> - </Filter> - <Filter - Name="Header Files" - Filter="h;hpp;hxx;hm;inl;inc;xsd" - UniqueIdentifier="{93995380-89BD-4b04-88EB-625FBE52EBFB}" - > - <File - RelativePath=".\jnicrypt.h" - > - </File> - </Filter> - <Filter - Name="Resource Files" - Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav" - UniqueIdentifier="{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}" - > - </Filter> - <File - RelativePath=".\ReadMe.txt" - > - </File> - </Files> - <Globals> - </Globals> -</VisualStudioProject> diff --git a/bundles/org.eclipse.equinox.security.win32.x86/forceQualifierUpdate.txt b/bundles/org.eclipse.equinox.security.win32.x86/forceQualifierUpdate.txt deleted file mode 100644 index 56f1032a8..000000000 --- a/bundles/org.eclipse.equinox.security.win32.x86/forceQualifierUpdate.txt +++ /dev/null @@ -1,2 +0,0 @@ -# To force a version qualifier update add the bug here -Bug 403352 - Update all parent versions to match our build stream diff --git a/bundles/org.eclipse.equinox.security.win32.x86/fragment.properties b/bundles/org.eclipse.equinox.security.win32.x86/fragment.properties deleted file mode 100644 index fa4837080..000000000 --- a/bundles/org.eclipse.equinox.security.win32.x86/fragment.properties +++ /dev/null @@ -1,17 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2009 IBM Corporation and others. -# -# This program and the accompanying materials -# are made available under the terms of the Eclipse Public License 2.0 -# which accompanies this distribution, and is available at -# https://www.eclipse.org/legal/epl-2.0/ -# -# SPDX-License-Identifier: EPL-2.0 -# -# Contributors: -# IBM Corporation - initial API and implementation -############################################################################### -fragmentName = Windows Data Protection services integration -providerName = Eclipse.org - Equinox -windowsModuleName = Windows Integration -providerDescription = The provider uses Windows APIs to encrypt a randomly generated \'master\' password in a way specific to the login credentials. Users who can log into the Windows account can access contents of the secure storage. diff --git a/bundles/org.eclipse.equinox.security.win32.x86/fragment.xml b/bundles/org.eclipse.equinox.security.win32.x86/fragment.xml deleted file mode 100644 index 371d17f2e..000000000 --- a/bundles/org.eclipse.equinox.security.win32.x86/fragment.xml +++ /dev/null @@ -1,18 +0,0 @@ -<?xml version="1.0" encoding="UTF-8"?> -<?eclipse version="3.2"?> -<fragment> - <extension - id="WindowsPasswordProvider" - name="%windowsModuleName" - point="org.eclipse.equinox.security.secureStorage"> - <provider - class="org.eclipse.equinox.internal.security.win32.WinCrypto" - description="%providerDescription" - priority="5"> - <hint - value="AutomaticPasswordGeneration"> - </hint> - </provider> - </extension> - -</fragment> diff --git a/bundles/org.eclipse.equinox.security.win32.x86/jnicrypt.dll b/bundles/org.eclipse.equinox.security.win32.x86/jnicrypt.dll Binary files differdeleted file mode 100644 index 5391937e8..000000000 --- a/bundles/org.eclipse.equinox.security.win32.x86/jnicrypt.dll +++ /dev/null diff --git a/bundles/org.eclipse.equinox.security.win32.x86/pom.xml b/bundles/org.eclipse.equinox.security.win32.x86/pom.xml deleted file mode 100644 index f4b41a174..000000000 --- a/bundles/org.eclipse.equinox.security.win32.x86/pom.xml +++ /dev/null @@ -1,56 +0,0 @@ -<?xml version="1.0" encoding="UTF-8"?> -<!-- - Copyright (c) 2012 Eclipse Foundation. - All rights reserved. This program and the accompanying materials - are made available under the terms of the Eclipse Distribution License v1.0 - which accompanies this distribution, and is available at - http://www.eclipse.org/org/documents/edl-v10.php - - Contributors: - Igor Fedorenko - initial implementation ---> -<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> - <modelVersion>4.0.0</modelVersion> - <parent> - <artifactId>rt.equinox.bundles</artifactId> - <groupId>org.eclipse.equinox.bundles</groupId> - <version>4.19.0-SNAPSHOT</version> - <relativePath>../../</relativePath> - </parent> - <groupId>org.eclipse.equinox</groupId> - <artifactId>org.eclipse.equinox.security.win32.x86</artifactId> - <version>1.1.100-SNAPSHOT</version> - <packaging>eclipse-plugin</packaging> - - <properties> - <skipAPIAnalysis>true</skipAPIAnalysis> - </properties> - - <build> - <plugins> - <plugin> - <groupId>org.eclipse.tycho</groupId> - <artifactId>target-platform-configuration</artifactId> - <configuration> - <environments> - <environment> - <os>win32</os> - <ws>win32</ws> - <arch>x86</arch> - </environment> - </environments> - <dependency-resolution> - <extraRequirements> - <requirement> - <!-- workaround usage of split package https://bugs.eclipse.org/bugs/show_bug.cgi?id=403196 --> - <id>org.eclipse.equinox.registry</id> - <versionRange>0.0.0</versionRange> - <type>p2-installable-unit</type> - </requirement> - </extraRequirements> - </dependency-resolution> - </configuration> - </plugin> - </plugins> - </build> -</project> diff --git a/bundles/org.eclipse.equinox.security.win32.x86/src/org/eclipse/equinox/internal/security/win32/WinCrypto.java b/bundles/org.eclipse.equinox.security.win32.x86/src/org/eclipse/equinox/internal/security/win32/WinCrypto.java deleted file mode 100644 index 4eb26e0d5..000000000 --- a/bundles/org.eclipse.equinox.security.win32.x86/src/org/eclipse/equinox/internal/security/win32/WinCrypto.java +++ /dev/null @@ -1,133 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2017 IBM Corporation and others. - * - * This program and the accompanying materials - * are made available under the terms of the Eclipse Public License 2.0 - * which accompanies this distribution, and is available at - * https://www.eclipse.org/legal/epl-2.0/ - * - * SPDX-License-Identifier: EPL-2.0 - * - * Contributors: - * IBM Corporation - initial API and implementation - *******************************************************************************/ -package org.eclipse.equinox.internal.security.win32; - -import java.io.IOException; -import java.security.SecureRandom; - -import javax.crypto.spec.PBEKeySpec; - -import org.eclipse.equinox.internal.security.auth.AuthPlugin; -import org.eclipse.equinox.internal.security.auth.nls.SecAuthMessages; -import org.eclipse.equinox.internal.security.storage.Base64; -import org.eclipse.equinox.internal.security.win32.nls.WinCryptoMessages; -import org.eclipse.equinox.security.storage.ISecurePreferences; -import org.eclipse.equinox.security.storage.StorageException; -import org.eclipse.equinox.security.storage.provider.IPreferencesContainer; -import org.eclipse.equinox.security.storage.provider.PasswordProvider; - -/** - * Provides interface with native Windows data protection API. This provider - * auto-generates separate passwords for each secure preferences tree. - */ -public class WinCrypto extends PasswordProvider { - - native public byte[] windecrypt(byte[] encryptedText); - - native public byte[] winencrypt(byte[] clearText); - - static { - System.loadLibrary("jnicrypt"); - } - - private final static String WIN_PROVIDER_NODE = "/org.eclipse.equinox.secure.storage/windows"; - private final static String PASSWORD_KEY = "encryptedPassword"; - - /** - * The length of the randomly generated password in bytes - */ - private final static int PASSWORD_LENGTH = 250; - - @Override - public PBEKeySpec getPassword(IPreferencesContainer container, int passwordType) { - byte[] encryptedPassword; - if ((passwordType & CREATE_NEW_PASSWORD) == 0) - encryptedPassword = getEncryptedPassword(container); - else - encryptedPassword = null; - - if (encryptedPassword != null) { - byte[] decryptedPassword = windecrypt(encryptedPassword); - if (decryptedPassword != null) { - String password = new String(decryptedPassword); - return new PBEKeySpec(password.toCharArray()); - } else { - StorageException e = new StorageException(StorageException.ENCRYPTION_ERROR, WinCryptoMessages.decryptPasswordFailed); - AuthPlugin.getDefault().logError(WinCryptoMessages.decryptPasswordFailed, e); - return null; - } - } - - // add info message in the log - AuthPlugin.getDefault().logMessage(WinCryptoMessages.newPasswordGenerated); - - byte[] rawPassword = new byte[PASSWORD_LENGTH]; - SecureRandom random = new SecureRandom(); - random.setSeed(System.currentTimeMillis()); - random.nextBytes(rawPassword); - String password = Base64.encode(rawPassword); - if (savePassword(password, container)) - return new PBEKeySpec(password.toCharArray()); - else - return null; - } - - private byte[] getEncryptedPassword(IPreferencesContainer container) { - ISecurePreferences node = container.getPreferences().node(WIN_PROVIDER_NODE); - String passwordHint; - try { - passwordHint = node.get(PASSWORD_KEY, null); - } catch (StorageException e) { // should never happen in this scenario - AuthPlugin.getDefault().logError(WinCryptoMessages.decryptPasswordFailed, e); - return null; - } - if (passwordHint == null) - return null; - return Base64.decode(passwordHint); - } - - private boolean savePassword(String password, IPreferencesContainer container){ - byte[] data = winencrypt(password.getBytes()); - if (data == null) { // this is bad. Something wrong with OS or JNI. - StorageException e = new StorageException(StorageException.ENCRYPTION_ERROR, WinCryptoMessages.encryptPasswordFailed); - AuthPlugin.getDefault().logError(WinCryptoMessages.encryptPasswordFailed, e); - return false; - } - String encodedEncryptyedPassword = Base64.encode(data); - ISecurePreferences node = container.getPreferences().node(WIN_PROVIDER_NODE); - try { - node.put(PASSWORD_KEY, encodedEncryptyedPassword, false); // note we don't recursively try to encrypt - } catch (StorageException e) { // should never happen in this scenario - AuthPlugin.getDefault().logError(SecAuthMessages.errorOnSave, e); - return false; - } - try { - node.flush(); // save right away - } catch (IOException e) { - AuthPlugin.getDefault().logError(SecAuthMessages.errorOnSave, e); - return false; - } - return true; - } - - @Override - public boolean retryOnError(Exception e, IPreferencesContainer container) { - // It would be rather dangerous to allow this password to be changed - // as it would permanently trash all entries in the secure storage. - // Rather applications using get...() should handle exceptions and offer to overwrite - // data on an entry-by-entry scale. - return false; - } - -} diff --git a/bundles/org.eclipse.equinox.security.win32.x86/src/org/eclipse/equinox/internal/security/win32/nls/WinCryptoMessages.java b/bundles/org.eclipse.equinox.security.win32.x86/src/org/eclipse/equinox/internal/security/win32/nls/WinCryptoMessages.java deleted file mode 100644 index bdafaec51..000000000 --- a/bundles/org.eclipse.equinox.security.win32.x86/src/org/eclipse/equinox/internal/security/win32/nls/WinCryptoMessages.java +++ /dev/null @@ -1,35 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 IBM Corporation and others. - * - * This program and the accompanying materials - * are made available under the terms of the Eclipse Public License 2.0 - * which accompanies this distribution, and is available at - * https://www.eclipse.org/legal/epl-2.0/ - * - * SPDX-License-Identifier: EPL-2.0 - * - * Contributors: - * IBM Corporation - initial API and implementation - *******************************************************************************/ -package org.eclipse.equinox.internal.security.win32.nls; - -import org.eclipse.osgi.util.NLS; - -public class WinCryptoMessages extends NLS { - - private static final String BUNDLE_NAME = "org.eclipse.equinox.internal.security.win32.nls.messages"; //$NON-NLS-1$ - - // Windows module - public static String encryptPasswordFailed; - public static String decryptPasswordFailed; - public static String newPasswordGenerated; - - static { - // load message values from bundle file - reloadMessages(); - } - - public static void reloadMessages() { - NLS.initializeMessages(BUNDLE_NAME, WinCryptoMessages.class); - } -}
\ No newline at end of file diff --git a/bundles/org.eclipse.equinox.security.win32.x86/src/org/eclipse/equinox/internal/security/win32/nls/messages.properties b/bundles/org.eclipse.equinox.security.win32.x86/src/org/eclipse/equinox/internal/security/win32/nls/messages.properties deleted file mode 100644 index b9f84e509..000000000 --- a/bundles/org.eclipse.equinox.security.win32.x86/src/org/eclipse/equinox/internal/security/win32/nls/messages.properties +++ /dev/null @@ -1,18 +0,0 @@ -############################################################################### -# Copyright (c) 2008 IBM Corporation and others. -# -# This program and the accompanying materials -# are made available under the terms of the Eclipse Public License 2.0 -# which accompanies this distribution, and is available at -# https://www.eclipse.org/legal/epl-2.0/ -# -# SPDX-License-Identifier: EPL-2.0 -# -# Contributors: -# IBM Corporation - initial API and implementation -############################################################################### - -## Windows module -encryptPasswordFailed = Unable to encrypt master password for storage. -decryptPasswordFailed = Secure storage was unable to retrieve the master password. If secure storage was created using a different Windows account, you'll have to switch back to that account. Alternatively, you can use the password recovery, or delete and re-create secure storage. -newPasswordGenerated = New keyring password generated. |