Fix account secrets page

This commit is contained in:
Li 2022-06-15 01:18:10 +12:00
parent be15542813
commit 627347372e
5 changed files with 1651 additions and 1285 deletions

View File

@ -31,11 +31,12 @@ namespace Default_PSN_Avatar
wc.Headers.Add("Cookie", "npsso=" + LoginFormCR.ssoCookie);
wc.Headers.Set("Origin", "https://id.sonyentertainmentnetwork.com");
wc.Headers.Set("Referer", "https://id.sonyentertainmentnetwork.com/id/management/");
wc.Headers.Set("User-Agent", "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/68.0.3440.106 Safari/537.36");
wc.Headers.Set("User-Agent", LoginFormCR.userAgentString);
wc.Redirects = false;
wc.DownloadString(@"https://ca.account.sony.com/api/v1/oauth/authorize?response_type=token&prompt=none&client_id=894cc20a-89f9-4e40-977c-76736871f7da&scope=kamaji%3Aget_account_hash%2Cuser%3Aaccount.address.get%2Cuser%3Aaccount.address.update%2Cuser%3Aaccount.core.get%2Cuser%3Aaccount.languages.get%2Cuser%3Aaccount.subaccounts.get%2Cversa%3Atv_get_dmas%2Cversa%3Auser_get_dma%2Cversa%3Auser_update_dma%2Cwallets%3Ainstrument.get%2Cwallets%3Ainstrument.verify%2Cwallets%3AmetaInfo.get%2C3DS%3AtransactionData.update&redirect_uri=https%3A%2F%2Ftransact.playstation.com%2Fhtml%2FwebIframeRedirect.html%3FrequestId%3D8901969a-9543-4950-acef-6a2e5a6fd458&ui=pr");
string Url = wc.ResponseUri.AbsoluteUri;
string Url = wc.ResponseHeaders.Get("Location");
if (Url.Contains("access_token"))
{

View File

@ -6,7 +6,6 @@ using System.Diagnostics;
using System.Drawing;
using System.Net;
using System.Text;
using System.Web;
using System.Windows.Forms;
namespace Default_PSN_Avatar
@ -17,6 +16,7 @@ namespace Default_PSN_Avatar
bool IsLoggingOut = false;
bool IsClosing = false;
bool GotSso = false;
public static string userAgentString;
public static string ssoCookie = null;
public static string bearer;
@ -195,7 +195,8 @@ namespace Default_PSN_Avatar
Random random = new Random(Guid.NewGuid().GetHashCode());
this.Size = new Size(574 + random.Next(-10, 100), 685 + random.Next(-10, 100));
userAgent.Text = GetLatestChromiumUserAgent();
userAgentString = GetLatestChromiumUserAgent();
userAgent.Text = userAgentString;
InitializeChromium(userAgent.Text);
}

View File

@ -18,6 +18,22 @@
<NuGetPackageImportStamp>
</NuGetPackageImportStamp>
<TargetFrameworkProfile />
<IsWebBootstrapper>false</IsWebBootstrapper>
<PublishUrl>publish\</PublishUrl>
<Install>true</Install>
<InstallFrom>Disk</InstallFrom>
<UpdateEnabled>false</UpdateEnabled>
<UpdateMode>Foreground</UpdateMode>
<UpdateInterval>7</UpdateInterval>
<UpdateIntervalUnits>Days</UpdateIntervalUnits>
<UpdatePeriodically>false</UpdatePeriodically>
<UpdateRequired>false</UpdateRequired>
<MapFileExtensions>true</MapFileExtensions>
<ApplicationRevision>1</ApplicationRevision>
<ApplicationVersion>1.0.0.%2a</ApplicationVersion>
<UseApplicationTrust>false</UseApplicationTrust>
<PublishWizardCompleted>true</PublishWizardCompleted>
<BootstrapperEnabled>true</BootstrapperEnabled>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<PlatformTarget>AnyCPU</PlatformTarget>
@ -66,6 +82,18 @@
<CodeAnalysisRuleSet>MinimumRecommendedRules.ruleset</CodeAnalysisRuleSet>
<Prefer32Bit>true</Prefer32Bit>
</PropertyGroup>
<PropertyGroup>
<ManifestCertificateThumbprint>C43AF237519A45162B78B139CBDF0C05DE12ED41</ManifestCertificateThumbprint>
</PropertyGroup>
<PropertyGroup>
<ManifestKeyFile>PSNInator_TemporaryKey.pfx</ManifestKeyFile>
</PropertyGroup>
<PropertyGroup>
<GenerateManifests>true</GenerateManifests>
</PropertyGroup>
<PropertyGroup>
<SignManifests>true</SignManifests>
</PropertyGroup>
<ItemGroup>
<Reference Include="CefSharp, Version=102.0.90.0, Culture=neutral, PublicKeyToken=40c4b6fc221f4138, processorArchitecture=MSIL">
<HintPath>..\packages\CefSharp.Common.102.0.90\lib\net452\CefSharp.dll</HintPath>
@ -193,6 +221,7 @@
<DependentUpon>Settings.settings</DependentUpon>
<DesignTimeSharedInput>True</DesignTimeSharedInput>
</Compile>
<None Include="PSNInator_TemporaryKey.pfx" />
</ItemGroup>
<ItemGroup>
<None Include="App.config" />
@ -206,6 +235,18 @@
<ItemGroup>
<Folder Include="Resources\" />
</ItemGroup>
<ItemGroup>
<BootstrapperPackage Include=".NETFramework,Version=v4.8">
<Visible>False</Visible>
<ProductName>Microsoft .NET Framework 4.8 %28x86 and x64%29</ProductName>
<Install>true</Install>
</BootstrapperPackage>
<BootstrapperPackage Include="Microsoft.Net.Framework.3.5.SP1">
<Visible>False</Visible>
<ProductName>.NET Framework 3.5 SP1</ProductName>
<Install>false</Install>
</BootstrapperPackage>
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<Target Name="EnsureNuGetPackageBuildImports" BeforeTargets="PrepareForBuild">
<PropertyGroup>

View File

@ -0,0 +1,16 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="Current" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<PublishUrlHistory />
<InstallUrlHistory />
<SupportUrlHistory />
<UpdateUrlHistory />
<BootstrapperUrlHistory />
<ErrorReportUrlHistory />
<FallbackCulture>en-US</FallbackCulture>
<VerifyUploadedFiles>false</VerifyUploadedFiles>
</PropertyGroup>
<PropertyGroup>
<EnableSecurityDebugging>false</EnableSecurityDebugging>
</PropertyGroup>
</Project>

File diff suppressed because it is too large Load Diff