mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2026-08-26 20:58:28 -05:00
Don't send Dolphin version in user agent to Redump
When we added the RetroAchievements integration, we had a discussion about whether sending version information in the user agent was fine from a privacy standpoint. We reached the conclusion that it was okay, but it was conditional on the website having a privacy policy. Neither incarnation of Redump has that, and Redump also never asked us to send version information like RetroAchievements did, so let's use a user agent that just says "Dolphin" when connecting to Redump.
This commit is contained in:
@@ -19,6 +19,12 @@ namespace Common
|
||||
#define BUILD_TYPE_STR ""
|
||||
#endif
|
||||
|
||||
const std::string& GetEmulatorName()
|
||||
{
|
||||
static const std::string emulator_name = EMULATOR_NAME;
|
||||
return emulator_name;
|
||||
}
|
||||
|
||||
const std::string& GetScmRevStr()
|
||||
{
|
||||
static const std::string scm_rev_str = EMULATOR_NAME " "
|
||||
|
||||
@@ -7,6 +7,7 @@
|
||||
|
||||
namespace Common
|
||||
{
|
||||
const std::string& GetEmulatorName();
|
||||
const std::string& GetScmDescStr();
|
||||
const std::string& GetScmBranchStr();
|
||||
const std::string& GetScmRevStr();
|
||||
|
||||
@@ -128,7 +128,7 @@ RedumpVerifier::DownloadStatus RedumpVerifier::DownloadDatfile(const std::string
|
||||
|
||||
const std::optional<std::vector<u8>> result =
|
||||
request.Get("https://redump.info/datfile/" + system + "/serial,version",
|
||||
{{"User-Agent", Common::GetScmRevStr()}});
|
||||
{{"User-Agent", Common::GetEmulatorName()}});
|
||||
|
||||
const std::string output_path = GetPathForSystem(system);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user