1 --- libcmis/src/libcmis/session-factory.cxx.orig 2024-06-21 17:40:02.696092806 +0200
2 +++ libcmis/src/libcmis/session-factory.cxx 2024-06-21 17:32:21.759833389 +0200
4 if ( bindingUrl == "https://www.googleapis.com/drive/v3" )
6 session = new GDriveSession( bindingUrl, username, password,
9 + g_CurlInitProtocolsFunction);
12 else if ( bindingUrl == "https://graph.microsoft.com/v1.0" )
14 session = new OneDriveSession( bindingUrl, username, password,
17 + g_CurlInitProtocolsFunction);
23 // Could be SharePoint - needs NTLM authentication
24 session = new SharePointSession( bindingUrl, username,
25 - password, verbose );
26 + password, verbose, g_CurlInitProtocolsFunction);
29 // Try the CMIS cases: we need to autodetect the binding type
30 --- libcmis/src/libcmis/base-session.hxx.orig 2024-06-21 17:41:56.737651815 +0200
31 +++ libcmis/src/libcmis/base-session.hxx 2024-06-21 17:42:08.466709308 +0200
33 BaseSession( std::string sBindingUrl, std::string repository,
34 std::string username, std::string password,
35 bool noSslCheck = false,
36 - libcmis::OAuth2DataPtr oauth2 = libcmis::OAuth2DataPtr(), bool verbose = false );
37 + libcmis::OAuth2DataPtr oauth2 = libcmis::OAuth2DataPtr(), bool verbose = false,
38 + libcmis::CurlInitProtocolsFunction = nullptr);
40 /** This constructor copies an existing http session.
41 This has been mostly designed for SessionFactory to save
42 --- libcmis/src/libcmis/base-session.cxx.orig 2024-06-21 17:42:28.593807967 +0200
43 +++ libcmis/src/libcmis/base-session.cxx 2024-06-21 17:43:37.051143529 +0200
47 BaseSession::BaseSession( string bindingUrl, string repositoryId, string username,
48 - string password, bool noSslCheck, libcmis::OAuth2DataPtr oauth2, bool verbose ) :
49 + string password, bool noSslCheck, libcmis::OAuth2DataPtr oauth2, bool verbose,
50 + libcmis::CurlInitProtocolsFunction initProtocolsFunction) :
52 - HttpSession( username, password, noSslCheck, oauth2, verbose ),
53 + HttpSession( username, password, noSslCheck, oauth2, verbose, initProtocolsFunction ),
54 m_bindingUrl( bindingUrl ),
55 m_repositoryId( repositoryId ),
57 --- libcmis/src/libcmis/gdrive-session.hxx.orig 2024-06-21 17:44:32.721416413 +0200
58 +++ libcmis/src/libcmis/gdrive-session.hxx 2024-06-21 17:39:01.143791090 +0200
62 libcmis::OAuth2DataPtr oauth2,
63 - bool verbose = false );
64 + bool verbose = false,
65 + libcmis::CurlInitProtocolsFunction = nullptr);
69 --- libcmis/src/libcmis/gdrive-session.cxx.orig 2024-06-21 17:44:59.947549870 +0200
70 +++ libcmis/src/libcmis/gdrive-session.cxx 2024-06-21 17:45:26.666680841 +0200
74 libcmis::OAuth2DataPtr oauth2,
77 + libcmis::CurlInitProtocolsFunction initProtocolsFunction) :
78 BaseSession( baseUrl, string(), username, password, false,
79 - libcmis::OAuth2DataPtr(), verbose )
80 + libcmis::OAuth2DataPtr(), verbose, initProtocolsFunction )
83 // Add the dummy repository, even if we don't have OAuth2
84 --- libcmis/src/libcmis/onedrive-session.hxx.orig 2024-06-21 17:46:39.857039605 +0200
85 +++ libcmis/src/libcmis/onedrive-session.hxx 2024-06-21 17:46:59.045133662 +0200
89 libcmis::OAuth2DataPtr oauth2,
90 - bool verbose = false );
91 + bool verbose = false,
92 + libcmis::CurlInitProtocolsFunction = nullptr);
96 --- libcmis/src/libcmis/onedrive-session.cxx.orig 2024-06-21 17:47:35.187310824 +0200
97 +++ libcmis/src/libcmis/onedrive-session.cxx 2024-06-21 17:48:02.068442589 +0200
101 libcmis::OAuth2DataPtr oauth2,
104 + libcmis::CurlInitProtocolsFunction initProtocolsFunction) :
105 BaseSession( baseUrl, string(), username, password, false,
106 - libcmis::OAuth2DataPtr(), verbose )
107 + libcmis::OAuth2DataPtr(), verbose, initProtocolsFunction)
110 // Add the dummy repository
111 --- libcmis/src/libcmis/sharepoint-session.hxx.orig 2024-06-21 18:02:35.120719197 +0200
112 +++ libcmis/src/libcmis/sharepoint-session.hxx 2024-06-21 18:02:54.288813088 +0200
114 SharePointSession( std::string baseUrl,
115 std::string username,
116 std::string password,
117 - bool verbose = false );
118 + bool verbose = false,
119 + libcmis::CurlInitProtocolsFunction = nullptr);
121 SharePointSession( std::string baseUrl,
122 const HttpSession& httpSession,
123 --- libcmis/src/libcmis/sharepoint-session.cxx.orig 2024-06-21 16:02:24.597237776 +0200
124 +++ libcmis/src/libcmis/sharepoint-session.cxx 2024-06-21 18:03:48.109076715 +0200
126 SharePointSession::SharePointSession ( string baseUrl,
131 + libcmis::CurlInitProtocolsFunction initProtocolsFunction) :
132 BaseSession( baseUrl, string(), username, password, false,
133 - libcmis::OAuth2DataPtr(), verbose ),
134 + libcmis::OAuth2DataPtr(), verbose, initProtocolsFunction ),
135 m_digestCode( string( ) )
138 --- libcmis/src/libcmis/http-session.cxx.orig 2024-06-21 18:24:44.192002619 +0200
139 +++ libcmis/src/libcmis/http-session.cxx 2024-06-21 18:24:46.329012530 +0200
141 case CURLE_COULDNT_RESOLVE_HOST:
144 + case CURLE_UNSUPPORTED_PROTOCOL:
145 case CURLE_COULDNT_CONNECT:
146 case CURLE_SSL_CONNECT_ERROR:
147 case CURLE_SSL_CERTPROBLEM: