Skip to content

Commit 1aa8b51

Browse files
committed
Merge branch 'fix-blink-curl' into blink
2 parents 78de960 + c321c57 commit 1aa8b51

File tree

7 files changed

+22
-13
lines changed

7 files changed

+22
-13
lines changed

curl/curl/lib/ssh.c

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,8 @@
2929
// If we have Blinkshell, we use their key management:
3030
#ifdef BLINKSHELL
3131
#import "BKDefaults.h"
32-
#import "BKHosts.h"
33-
#import "BKPubKey.h"
32+
#import <BlinkConfig/BKHosts.h>
33+
#import <BlinkConfig/BKPubKey.h>
3434
#endif
3535

3636
#ifdef HAVE_LIMITS_H
@@ -848,7 +848,7 @@ static CURLcode ssh_statemach_act(struct connectdata *conn, bool *block)
848848
// key associated with this hostname
849849
if ((pk = [BKPubKey withID:[NSString stringWithUTF8String:data->set.str[STRING_SSH_PRIVATE_KEY]]]) != nil) {
850850
publicKeyMemory = [pk.publicKey UTF8String];
851-
privateKeyMemory = [pk.privateKey UTF8String];
851+
privateKeyMemory = [[pk loadPrivateKey] UTF8String];
852852
sshc->rsa = data->set.str[STRING_SSH_PRIVATE_KEY];
853853
}
854854
}
@@ -857,7 +857,7 @@ static CURLcode ssh_statemach_act(struct connectdata *conn, bool *block)
857857
if (host.key) {
858858
if ((pk = [BKPubKey withID:host.key]) != nil) {
859859
publicKeyMemory = [pk.publicKey UTF8String];
860-
privateKeyMemory = [pk.privateKey UTF8String];
860+
privateKeyMemory = [[pk loadPrivateKey] UTF8String];
861861
sshc->rsa = strdup(host.key.UTF8String);
862862
}
863863
}
@@ -869,15 +869,15 @@ static CURLcode ssh_statemach_act(struct connectdata *conn, bool *block)
869869
// Priority 2: key named id_rsa:
870870
if ((pk = [BKPubKey withID:@"id_rsa"]) != nil) {
871871
publicKeyMemory = [pk.publicKey UTF8String];
872-
privateKeyMemory = [pk.privateKey UTF8String];
872+
privateKeyMemory = [[pk loadPrivateKey] UTF8String];
873873
sshc->rsa = strdup("id_rsa");
874874
}
875875
}
876876
if (!(privateKeyMemory && publicKeyMemory)) {
877877
// Still no luck, try with id_dsa:
878878
if ((pk = [BKPubKey withID:@"id_dsa"]) != nil) {
879879
publicKeyMemory = [pk.publicKey UTF8String];
880-
privateKeyMemory = [pk.privateKey UTF8String];
880+
privateKeyMemory = [[pk loadPrivateKey] UTF8String];
881881
sshc->rsa = strdup("id_dsa");
882882
}
883883
}

curl/curl/lib/url.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -123,7 +123,7 @@ bool curl_win32_idn_to_ascii(const char *in, char **out);
123123
// If we have Blinkshell, we use their key management:
124124
#ifdef BLINKSHELL
125125
#import "BKDefaults.h"
126-
#import "BKHosts.h"
126+
#import <BlinkConfig/BKHosts.h>
127127
#endif
128128

129129
// from ios_error.h, but without the compileError:

curl/curl/src/tool_main.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -236,6 +236,7 @@ static void main_free(struct GlobalConfig *config)
236236
* scp localFile user@host:~/path/ => curl -T localFile scp://user@host/~/path/localFile
237237
*/
238238
#ifdef BLINKSHELL
239+
__attribute__ ((visibility("default")))
239240
int curl_static_main(int argc, char *argv[]);
240241
#else
241242
int curl_main(int argc, char *argv[]);

curl_ios_static.xcodeproj/project.pbxproj

Lines changed: 14 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -356,8 +356,9 @@
356356
2219E2CB1FD7E58600675252 /* tool_writeout.h in Headers */ = {isa = PBXBuildFile; fileRef = 2219E2681FD7E58600675252 /* tool_writeout.h */; };
357357
2219E2CC1FD7E58600675252 /* tool_xattr.c in Sources */ = {isa = PBXBuildFile; fileRef = 2219E2691FD7E58600675252 /* tool_xattr.c */; };
358358
2219E2CD1FD7E58600675252 /* tool_xattr.h in Headers */ = {isa = PBXBuildFile; fileRef = 2219E26A1FD7E58600675252 /* tool_xattr.h */; };
359-
D271F98725B5B7DF005F88E5 /* openssl.xcframework in Frameworks */ = {isa = PBXBuildFile; fileRef = D271F98525B5B7DF005F88E5 /* openssl.xcframework */; };
360-
D271F98825B5B7DF005F88E5 /* libssh2.xcframework in Frameworks */ = {isa = PBXBuildFile; fileRef = D271F98625B5B7DF005F88E5 /* libssh2.xcframework */; };
359+
D224184D26EA0BD10078E35E /* BlinkConfig.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = D224184C26EA0BD10078E35E /* BlinkConfig.framework */; };
360+
D2D492BC25CD81E0007659F1 /* libssh2.xcframework in Frameworks */ = {isa = PBXBuildFile; fileRef = D2D492BB25CD81D0007659F1 /* libssh2.xcframework */; };
361+
D2D492C025CD81EA007659F1 /* openssl.xcframework in Frameworks */ = {isa = PBXBuildFile; fileRef = D2D492BF25CD81EA007659F1 /* openssl.xcframework */; };
361362
/* End PBXBuildFile section */
362363

363364
/* Begin PBXFileReference section */
@@ -713,17 +714,21 @@
713714
2219E2681FD7E58600675252 /* tool_writeout.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = tool_writeout.h; sourceTree = "<group>"; };
714715
2219E2691FD7E58600675252 /* tool_xattr.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = tool_xattr.c; sourceTree = "<group>"; };
715716
2219E26A1FD7E58600675252 /* tool_xattr.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = tool_xattr.h; sourceTree = "<group>"; };
717+
D224184C26EA0BD10078E35E /* BlinkConfig.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; path = BlinkConfig.framework; sourceTree = BUILT_PRODUCTS_DIR; };
716718
D271F98525B5B7DF005F88E5 /* openssl.xcframework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.xcframework; name = openssl.xcframework; path = xcfs/.build/artifacts/xcfs/openssl.xcframework; sourceTree = "<group>"; };
717719
D271F98625B5B7DF005F88E5 /* libssh2.xcframework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.xcframework; name = libssh2.xcframework; path = xcfs/.build/artifacts/xcfs/libssh2.xcframework; sourceTree = "<group>"; };
720+
D2D492BB25CD81D0007659F1 /* libssh2.xcframework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.xcframework; name = libssh2.xcframework; path = ../../xcfs/.build/artifacts/xcfs/libssh2.xcframework; sourceTree = "<group>"; };
721+
D2D492BF25CD81EA007659F1 /* openssl.xcframework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.xcframework; name = openssl.xcframework; path = ../../xcfs/.build/artifacts/xcfs/openssl.xcframework; sourceTree = "<group>"; };
718722
/* End PBXFileReference section */
719723

720724
/* Begin PBXFrameworksBuildPhase section */
721725
2219DFCB1FD73AF500675252 /* Frameworks */ = {
722726
isa = PBXFrameworksBuildPhase;
723727
buildActionMask = 2147483647;
724728
files = (
725-
D271F98725B5B7DF005F88E5 /* openssl.xcframework in Frameworks */,
726-
D271F98825B5B7DF005F88E5 /* libssh2.xcframework in Frameworks */,
729+
D2D492C025CD81EA007659F1 /* openssl.xcframework in Frameworks */,
730+
D224184D26EA0BD10078E35E /* BlinkConfig.framework in Frameworks */,
731+
D2D492BC25CD81E0007659F1 /* libssh2.xcframework in Frameworks */,
727732
);
728733
runOnlyForDeploymentPostprocessing = 0;
729734
};
@@ -1142,6 +1147,9 @@
11421147
2219E2D01FD7EDE600675252 /* Frameworks */ = {
11431148
isa = PBXGroup;
11441149
children = (
1150+
D224184C26EA0BD10078E35E /* BlinkConfig.framework */,
1151+
D2D492BF25CD81EA007659F1 /* openssl.xcframework */,
1152+
D2D492BB25CD81D0007659F1 /* libssh2.xcframework */,
11451153
D271F98625B5B7DF005F88E5 /* libssh2.xcframework */,
11461154
D271F98525B5B7DF005F88E5 /* openssl.xcframework */,
11471155
);
@@ -1728,7 +1736,7 @@
17281736
SKIP_INSTALL = YES;
17291737
STRIP_INSTALLED_PRODUCT = NO;
17301738
STRIP_STYLE = "non-global";
1731-
TARGETED_DEVICE_FAMILY = "1,2";
1739+
TARGETED_DEVICE_FAMILY = "1,2,6";
17321740
};
17331741
name = Debug;
17341742
};
@@ -1769,7 +1777,7 @@
17691777
SKIP_INSTALL = YES;
17701778
STRIP_INSTALLED_PRODUCT = NO;
17711779
STRIP_STYLE = "non-global";
1772-
TARGETED_DEVICE_FAMILY = "1,2";
1780+
TARGETED_DEVICE_FAMILY = "1,2,6";
17731781
};
17741782
name = Release;
17751783
};

file_cmds/.DS_Store

-10 KB
Binary file not shown.

less-34/.DS_Store

-6 KB
Binary file not shown.

text_cmds/.DS_Store

-6 KB
Binary file not shown.

0 commit comments

Comments
 (0)