version: Bump version to 34.0.0.164 and fix ownership issues

test-ci
Daniel 4 years ago
parent 91c09ff019
commit 606d5c1e47

@ -72,6 +72,7 @@
<Compile Include="SystemInfo.cs" /> <Compile Include="SystemInfo.cs" />
<Compile Include="Uninstaller.cs" /> <Compile Include="Uninstaller.cs" />
<Compile Include="UpdateChecker.cs" /> <Compile Include="UpdateChecker.cs" />
<Compile Include="WinAPI.cs" />
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<EmbeddedResource Include="Properties\Resources.resx"> <EmbeddedResource Include="Properties\Resources.resx">

@ -18,6 +18,10 @@ namespace CleanFlashCommon {
"seamonkey", "palemoon", "plugin-container" "seamonkey", "palemoon", "plugin-container"
}; };
static Uninstaller() {
WinAPI.AllowModifications();
}
public static void UninstallRegistry() { public static void UninstallRegistry() {
if (Environment.Is64BitOperatingSystem) { if (Environment.Is64BitOperatingSystem) {
RegistryManager.ApplyRegistry(Properties.Resources.uninstallRegistry, Properties.Resources.uninstallRegistry64); RegistryManager.ApplyRegistry(Properties.Resources.uninstallRegistry, Properties.Resources.uninstallRegistry64);

@ -32,8 +32,8 @@ namespace CleanFlashCommon {
} }
public class UpdateChecker { public class UpdateChecker {
private static readonly string FLASH_VERSION = "34.0.0.155"; private static readonly string FLASH_VERSION = "34.0.0.164";
private static readonly string VERSION = "v34.0.0.155"; private static readonly string VERSION = "v34.0.0.164";
private static readonly string FLASH_PLAYER_EXECUTABLE = "flashplayer_sa.exe"; private static readonly string FLASH_PLAYER_EXECUTABLE = "flashplayer_sa.exe";
private static readonly string AUTHOR = "cleanflash"; private static readonly string AUTHOR = "cleanflash";
private static readonly string REPO = "installer"; private static readonly string REPO = "installer";

@ -0,0 +1,108 @@
using System;
using System.ComponentModel;
using System.Runtime.InteropServices;
using System.Security.Principal;
namespace CleanFlashCommon {
public class WinAPI {
public static void AllowModifications() {
ModifyPrivilege(PrivilegeName.SeRestorePrivilege, true);
ModifyPrivilege(PrivilegeName.SeTakeOwnershipPrivilege, true);
}
public static bool ModifyPrivilege(PrivilegeName privilege, bool enable) {
LUID luid;
if (!LookupPrivilegeValue(null, privilege.ToString(), out luid)) {
throw new Win32Exception();
}
using (var identity = WindowsIdentity.GetCurrent(TokenAccessLevels.AdjustPrivileges | TokenAccessLevels.Query)) {
var newPriv = new TOKEN_PRIVILEGES();
newPriv.Privileges = new LUID_AND_ATTRIBUTES[1];
newPriv.PrivilegeCount = 1;
newPriv.Privileges[0].Luid = luid;
newPriv.Privileges[0].Attributes = enable ? SE_PRIVILEGE_ENABLED : 0;
var prevPriv = new TOKEN_PRIVILEGES();
prevPriv.Privileges = new LUID_AND_ATTRIBUTES[1];
prevPriv.PrivilegeCount = 1;
uint returnedBytes;
if (!AdjustTokenPrivileges(identity.Token, false, ref newPriv, (uint)Marshal.SizeOf(prevPriv), ref prevPriv, out returnedBytes)) {
throw new Win32Exception();
}
return prevPriv.PrivilegeCount == 0 ? enable /* didn't make a change */ : ((prevPriv.Privileges[0].Attributes & SE_PRIVILEGE_ENABLED) != 0);
}
}
const uint SE_PRIVILEGE_ENABLED = 2;
[DllImport("advapi32.dll", SetLastError = true)]
[return: MarshalAs(UnmanagedType.Bool)]
static extern bool AdjustTokenPrivileges(IntPtr TokenHandle, [MarshalAs(UnmanagedType.Bool)] bool DisableAllPrivileges, ref TOKEN_PRIVILEGES NewState,
UInt32 BufferLengthInBytes, ref TOKEN_PRIVILEGES PreviousState, out UInt32 ReturnLengthInBytes);
[DllImport("advapi32.dll", SetLastError = true, CharSet = CharSet.Auto)]
[return: MarshalAs(UnmanagedType.Bool)]
static extern bool LookupPrivilegeValue(string lpSystemName, string lpName, out LUID lpLuid);
struct TOKEN_PRIVILEGES {
public UInt32 PrivilegeCount;
[MarshalAs(UnmanagedType.ByValArray, SizeConst = 1 /*ANYSIZE_ARRAY*/)]
public LUID_AND_ATTRIBUTES[] Privileges;
}
[StructLayout(LayoutKind.Sequential)]
struct LUID_AND_ATTRIBUTES {
public LUID Luid;
public UInt32 Attributes;
}
[StructLayout(LayoutKind.Sequential)]
struct LUID {
public uint LowPart;
public int HighPart;
}
}
public enum PrivilegeName {
SeAssignPrimaryTokenPrivilege,
SeAuditPrivilege,
SeBackupPrivilege,
SeChangeNotifyPrivilege,
SeCreateGlobalPrivilege,
SeCreatePagefilePrivilege,
SeCreatePermanentPrivilege,
SeCreateSymbolicLinkPrivilege,
SeCreateTokenPrivilege,
SeDebugPrivilege,
SeEnableDelegationPrivilege,
SeImpersonatePrivilege,
SeIncreaseBasePriorityPrivilege,
SeIncreaseQuotaPrivilege,
SeIncreaseWorkingSetPrivilege,
SeLoadDriverPrivilege,
SeLockMemoryPrivilege,
SeMachineAccountPrivilege,
SeManageVolumePrivilege,
SeProfileSingleProcessPrivilege,
SeRelabelPrivilege,
SeRemoteShutdownPrivilege,
SeRestorePrivilege,
SeSecurityPrivilege,
SeShutdownPrivilege,
SeSyncAgentPrivilege,
SeSystemEnvironmentPrivilege,
SeSystemProfilePrivilege,
SeSystemtimePrivilege,
SeTakeOwnershipPrivilege,
SeTcbPrivilege,
SeTimeZonePrivilege,
SeTrustedCredManAccessPrivilege,
SeUndockPrivilege,
SeUnsolicitedInputPrivilege,
}
}

@ -5,11 +5,11 @@ using System.Runtime.InteropServices;
// General Information about an assembly is controlled through the following // General Information about an assembly is controlled through the following
// set of attributes. Change these attribute values to modify the information // set of attributes. Change these attribute values to modify the information
// associated with an assembly. // associated with an assembly.
[assembly: AssemblyTitle("Clean Flash Player 34.0.0.155 Installer")] [assembly: AssemblyTitle("Clean Flash Player 34.0.0.164 Installer")]
[assembly: AssemblyDescription("The newest version of Flash Player, patched and ready to go beyond 2021.")] [assembly: AssemblyDescription("The newest version of Flash Player, patched and ready to go beyond 2021.")]
[assembly: AssemblyConfiguration("")] [assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("FlashPatch Team")] [assembly: AssemblyCompany("FlashPatch Team")]
[assembly: AssemblyProduct("Clean Flash Player 34.0.0.155 Installer")] [assembly: AssemblyProduct("Clean Flash Player 34.0.0.164 Installer")]
[assembly: AssemblyCopyright("")] [assembly: AssemblyCopyright("")]
[assembly: AssemblyTrademark("")] [assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")] [assembly: AssemblyCulture("")]
@ -32,5 +32,5 @@ using System.Runtime.InteropServices;
// You can specify all the values or you can default the Build and Revision Numbers // You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below: // by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")] // [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("34.0.0.155")] [assembly: AssemblyVersion("34.0.0.164")]
[assembly: AssemblyFileVersion("34.0.0.155")] [assembly: AssemblyFileVersion("34.0.0.164")]

@ -146,23 +146,26 @@ namespace CleanFlashInstaller.Properties {
} }
/// <summary> /// <summary>
/// Looks up a localized string similar to [HKEY_LOCAL_MACHINE\Software\Classes\.mfp] /// Looks up a localized string similar to [HKEY_LOCAL_MACHINE\Software\Macromedia\FlashPlayer]
///&quot;Content Type&quot;=&quot;application/x-shockwave-flash&quot; ///&quot;CurrentVersion&quot;=&quot;${VERSION_COMMA}&quot;
///@=&quot;MacromediaFlashPaper.MacromediaFlashPaper&quot;
///
///[HKEY_LOCAL_MACHINE\Software\Classes\.sol]
///&quot;Content Type&quot;=&quot;text/plain&quot;
///
///[HKEY_LOCAL_MACHINE\Software\Classes\.sor]
///&quot;Content Type&quot;=&quot;text/plain&quot;
///
///[HKEY_LOCAL_MACHINE\Software\Classes\.spl]
///&quot;Content Type&quot;=&quot;application/futuresplash&quot;
///@=&quot;ShockwaveFlash.ShockwaveFlash&quot;
/// ///
///[HKEY_LOCAL_MACHINE\Software\Classes\.swf] ///[HKEY_LOCAL_MACHINE\Software\Macromedia\FlashPlayer\SafeVersions]
///&quot;Content Type&quot;=&quot;application/x-shockwave-flash&quot; ///&quot;20.0&quot;=dword:ffffffff
///@=&quot;Sh [rest of string was truncated]&quot;;. ///&quot;21.0&quot;=dword:ffffffff
///&quot;22.0&quot;=dword:ffffffff
///&quot;23.0&quot;=dword:ffffffff
///&quot;24.0&quot;=dword:ffffffff
///&quot;25.0&quot;=dword:ffffffff
///&quot;26.0&quot;=dword:ffffffff
///&quot;27.0&quot;=dword:ffffffff
///&quot;28.0&quot;=dword:ffffffff
///&quot;19.0&quot;=dword:ffffffff
///&quot;30.0&quot;=dword:ffffffff
///&quot;31.0&quot;=dword:ffffffff
///&quot;32.0&quot;=dword:ffffffff
///&quot;33.0&quot;=dword:ffffffff
///&quot;34.0&quot;=dword:00000089
///&quot;16.0&quot;= [rest of string was truncated]&quot;;.
/// </summary> /// </summary>
internal static string installOCX { internal static string installOCX {
get { get {

@ -1,17 +1,17 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<root> <root>
<!-- <!--
Microsoft ResX Schema Microsoft ResX Schema
Version 2.0 Version 2.0
The primary goals of this format is to allow a simple XML format The primary goals of this format is to allow a simple XML format
that is mostly human readable. The generation and parsing of the that is mostly human readable. The generation and parsing of the
various data types are done through the TypeConverter classes various data types are done through the TypeConverter classes
associated with the data types. associated with the data types.
Example: Example:
... ado.net/XML headers & schema ... ... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader> <resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader> <resheader name="version">2.0</resheader>
@ -26,36 +26,36 @@
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value> <value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
<comment>This is a comment</comment> <comment>This is a comment</comment>
</data> </data>
There are any number of "resheader" rows that contain simple There are any number of "resheader" rows that contain simple
name/value pairs. name/value pairs.
Each data row contains a name, and value. The row also contains a Each data row contains a name, and value. The row also contains a
type or mimetype. Type corresponds to a .NET class that support type or mimetype. Type corresponds to a .NET class that support
text/value conversion through the TypeConverter architecture. text/value conversion through the TypeConverter architecture.
Classes that don't support this are serialized and stored with the Classes that don't support this are serialized and stored with the
mimetype set. mimetype set.
The mimetype is used for serialized objects, and tells the The mimetype is used for serialized objects, and tells the
ResXResourceReader how to depersist the object. This is currently not ResXResourceReader how to depersist the object. This is currently not
extensible. For a given mimetype the value must be set accordingly: extensible. For a given mimetype the value must be set accordingly:
Note - application/x-microsoft.net.object.binary.base64 is the format Note - application/x-microsoft.net.object.binary.base64 is the format
that the ResXResourceWriter will generate, however the reader can that the ResXResourceWriter will generate, however the reader can
read any of the formats listed below. read any of the formats listed below.
mimetype: application/x-microsoft.net.object.binary.base64 mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter : System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding. : and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64 mimetype: application/x-microsoft.net.object.soap.base64
value : The object must be serialized with value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter : System.Runtime.Serialization.Formatters.Soap.SoapFormatter
: and then encoded with base64 encoding. : and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.bytearray.base64 mimetype: application/x-microsoft.net.object.bytearray.base64
value : The object must be serialized into a byte array value : The object must be serialized into a byte array
: using a System.ComponentModel.TypeConverter : using a System.ComponentModel.TypeConverter
: and then encoded with base64 encoding. : and then encoded with base64 encoding.
--> -->
@ -198,25 +198,7 @@
"DisableExceptionChainValidation"=dword:00000000</value> "DisableExceptionChainValidation"=dword:00000000</value>
</data> </data>
<data name="installOCX" xml:space="preserve"> <data name="installOCX" xml:space="preserve">
<value>[HKEY_LOCAL_MACHINE\Software\Classes\.mfp] <value>[HKEY_LOCAL_MACHINE\Software\Macromedia\FlashPlayer]
"Content Type"="application/x-shockwave-flash"
@="MacromediaFlashPaper.MacromediaFlashPaper"
[HKEY_LOCAL_MACHINE\Software\Classes\.sol]
"Content Type"="text/plain"
[HKEY_LOCAL_MACHINE\Software\Classes\.sor]
"Content Type"="text/plain"
[HKEY_LOCAL_MACHINE\Software\Classes\.spl]
"Content Type"="application/futuresplash"
@="ShockwaveFlash.ShockwaveFlash"
[HKEY_LOCAL_MACHINE\Software\Classes\.swf]
"Content Type"="application/x-shockwave-flash"
@="ShockwaveFlash.ShockwaveFlash"
[HKEY_LOCAL_MACHINE\Software\Macromedia\FlashPlayer]
"CurrentVersion"="${VERSION_COMMA}" "CurrentVersion"="${VERSION_COMMA}"
[HKEY_LOCAL_MACHINE\Software\Macromedia\FlashPlayer\SafeVersions] [HKEY_LOCAL_MACHINE\Software\Macromedia\FlashPlayer\SafeVersions]
@ -260,17 +242,7 @@
"isESR"=dword:00000000 "isESR"=dword:00000000
[HKEY_LOCAL_MACHINE\Software\Macromedia\FlashPlayerActiveXReleaseType] [HKEY_LOCAL_MACHINE\Software\Macromedia\FlashPlayerActiveXReleaseType]
"Release"=dword:00000001 "Release"=dword:00000001</value>
[HKEY_LOCAL_MACHINE\Software\Microsoft\Internet Explorer\ActiveX Compatibility\{D27CDB6E-AE6D-11CF-96B8-444553540000}]
"Compatibility Flags"=dword:00000000
[HKEY_LOCAL_MACHINE\Software\Microsoft\Internet Explorer\ActiveX Compatibility\{D27CDB70-AE6D-11cf-96B8-444553540000}]
"Compatibility Flags"=dword:00010000
[HKEY_LOCAL_MACHINE\Software\Microsoft\Internet Explorer\NavigatorPluginsList\Shockwave Flash]
"application/futuresplash"=""
"application/x-shockwave-flash"=""</value>
</data> </data>
<data name="installOCX64" xml:space="preserve"> <data name="installOCX64" xml:space="preserve">
<value>[HKEY_LOCAL_MACHINE\Software\Wow6432Node\Macromedia\FlashPlayer] <value>[HKEY_LOCAL_MACHINE\Software\Wow6432Node\Macromedia\FlashPlayer]
@ -317,17 +289,7 @@
"isPartner"=dword:00000001 "isPartner"=dword:00000001
[HKEY_LOCAL_MACHINE\Software\Wow6432Node\Macromedia\FlashPlayerActiveXReleaseType] [HKEY_LOCAL_MACHINE\Software\Wow6432Node\Macromedia\FlashPlayerActiveXReleaseType]
"Release"=dword:00000001 "Release"=dword:00000001</value>
[HKEY_LOCAL_MACHINE\Software\Wow6432Node\Microsoft\Internet Explorer\ActiveX Compatibility\{D27CDB6E-AE6D-11CF-96B8-444553540000}]
"Compatibility Flags"=dword:00000000
[HKEY_LOCAL_MACHINE\Software\Wow6432Node\Microsoft\Internet Explorer\ActiveX Compatibility\{D27CDB70-AE6D-11cf-96B8-444553540000}]
"Compatibility Flags"=dword:00010000
[HKEY_LOCAL_MACHINE\Software\Wow6432Node\Microsoft\Internet Explorer\NavigatorPluginsList\Shockwave Flash]
"application/x-shockwave-flash"=""
"application/futuresplash"=""</value>
</data> </data>
<data name="installPP" xml:space="preserve"> <data name="installPP" xml:space="preserve">
<value>[HKEY_LOCAL_MACHINE\Software\Macromedia\FlashPlayerPepper] <value>[HKEY_LOCAL_MACHINE\Software\Macromedia\FlashPlayerPepper]
@ -355,4 +317,4 @@
[HKEY_LOCAL_MACHINE\Software\Wow6432Node\Macromedia\FlashPlayerPepperReleaseType] [HKEY_LOCAL_MACHINE\Software\Wow6432Node\Macromedia\FlashPlayerPepperReleaseType]
"Release"=dword:00000001</value> "Release"=dword:00000001</value>
</data> </data>
</root> </root>

@ -5,11 +5,11 @@ using System.Runtime.InteropServices;
// General Information about an assembly is controlled through the following // General Information about an assembly is controlled through the following
// set of attributes. Change these attribute values to modify the information // set of attributes. Change these attribute values to modify the information
// associated with an assembly. // associated with an assembly.
[assembly: AssemblyTitle("Clean Flash Player 34.0.0.155 Uninstaller")] [assembly: AssemblyTitle("Clean Flash Player 34.0.0.164 Uninstaller")]
[assembly: AssemblyDescription("The newest version of Flash Player, patched and ready to go beyond 2021.")] [assembly: AssemblyDescription("The newest version of Flash Player, patched and ready to go beyond 2021.")]
[assembly: AssemblyConfiguration("")] [assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("FlashPatch Team")] [assembly: AssemblyCompany("FlashPatch Team")]
[assembly: AssemblyProduct("Clean Flash Player 34.0.0.155 Uninstaller")] [assembly: AssemblyProduct("Clean Flash Player 34.0.0.164 Uninstaller")]
[assembly: AssemblyCopyright("")] [assembly: AssemblyCopyright("")]
[assembly: AssemblyTrademark("")] [assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")] [assembly: AssemblyCulture("")]
@ -32,5 +32,5 @@ using System.Runtime.InteropServices;
// You can specify all the values or you can default the Build and Revision Numbers // You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below: // by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")] // [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("34.0.0.155")] [assembly: AssemblyVersion("34.0.0.164")]
[assembly: AssemblyFileVersion("34.0.0.155")] [assembly: AssemblyFileVersion("34.0.0.164")]

Loading…
Cancel
Save