mirror of
https://github.com/moonlight-stream/moonlight-qt.git
synced 2026-06-20 15:40:58 +00:00
Add server cert pinning after pairing
This commit is contained in:
@@ -28,5 +28,6 @@
|
||||
@property BOOL enableHdr;
|
||||
@property BOOL multiController;
|
||||
@property BOOL allowHevc;
|
||||
@property NSData* serverCert;
|
||||
|
||||
@end
|
||||
|
||||
@@ -9,5 +9,5 @@
|
||||
#import "StreamConfiguration.h"
|
||||
|
||||
@implementation StreamConfiguration
|
||||
@synthesize host, appID, width, height, frameRate, bitRate, riKeyId, riKey, gamepadMask, streamingRemotely, appName, optimizeGameSettings, playAudioOnPC, audioChannelMask, audioChannelCount, enableHdr, multiController, allowHevc;
|
||||
@synthesize host, appID, width, height, frameRate, bitRate, riKeyId, riKey, gamepadMask, streamingRemotely, appName, optimizeGameSettings, playAudioOnPC, audioChannelMask, audioChannelCount, enableHdr, multiController, allowHevc, serverCert;
|
||||
@end
|
||||
|
||||
@@ -38,12 +38,10 @@
|
||||
- (void)main {
|
||||
[CryptoManager generateKeyPairUsingSSL];
|
||||
NSString* uniqueId = [IdManager getUniqueId];
|
||||
NSData* cert = [CryptoManager readCertFromFile];
|
||||
|
||||
HttpManager* hMan = [[HttpManager alloc] initWithHost:_config.host
|
||||
uniqueId:uniqueId
|
||||
deviceName:deviceName
|
||||
cert:cert];
|
||||
serverCert:_config.serverCert];
|
||||
|
||||
ServerInfoResponse* serverInfoResp = [[ServerInfoResponse alloc] init];
|
||||
[hMan executeRequestSynchronously:[HttpRequest requestForResponse:serverInfoResp withUrlRequest:[hMan newServerInfoRequest:false]
|
||||
|
||||
Reference in New Issue
Block a user