19

Code See this for the main issue that made it take so long to get this up If you just want the service connection you can get it like this: PacletInstall["ServiceConnection_GoogleDrive", "Site"->"http://www.wolframcloud.com/objects/b3m2a1.paclets/PacletServer" ] Post So this turned out to be a bit of a bear to get the details right for, but not ...


8

Update Here's a cleaner rewrite of my original: First authenticate: $so = ServiceConnect["Twitter", "New"]; Then extract: ServiceConnections`Private`serviceAuthentication[$so[[-1, -1]]][[2]] OAuthSigning`Private`Token10[ "806596495344603136-CEWIkGjWYevKFKsUT7uJ5XCLoLWyON2", "NuE2kf4PjPNkzUCpb6dASqjMfMoXbE07ACTj7YImeMb1R&...


7

In general SendMail should not access an email account that stores important emails or that functions to reset the passwords of other online accounts. Such a valuable email account should be protected by two-factor authentication as well as user-managed access such as OAuth, and so forth. Because SendMail does not support any such features it can not access ...


6

Google Cloud Platform uses the RS256 algorithm to send JWT and retrieve the tokens, all that is needed is to make a function that builds the JWT and creates a signature using GenerateDigitalSignature[]. FixB64[str_?StringQ] := StringReplace[StringSplit[str, "="][[1]], {"+" -> "-", "/" -> "_"}]; ...


6

You can also do this through the ServiceConnect framework. I detailed how to build one of these connections here and how to do it for Google Drive here To start, here's how you can get the paclet that implements the connection: PacletInstall["ServiceConnection_GoogleDrive", "Site"->"http://www.wolframcloud.com/objects/b3m2a1.paclets/PacletServer" ] ...


5

Before running the commands, one needs to sign into the cloud using one's WolframID credentials, CloudConnect[userid, pwd] Userid and/or pwd can be left if you want to be prompted.


4

ExportString[ FromCharacterCode[ IntegerDigits[ Hash["333", "SHA512"], 256] ], "Base64"] (* XjFVd0052XxfnhfBCMKz4EhaQ64069GW9hpvi/cy73GknlcQWUz8c5HbEU7fmfXaPtlu8dbKXlmOhfkb1B5+6w== *) Your use of IntegerString converts it to base-16 first, but it looks like you want to convert it on a per-bit level, so divide it into bytes (with ...


4

Here's how I decided to include this in my service connections. First, I tweaked my template to search out one of these files in my paclet or the "ApplicationData" subdir of $UserBaseDirectory: $$serviceconnectionclientsecretsjsonfile= If[StringQ@#, FileNameJoin@{ #, "client_secrets.json" }, None ...


4

In version 11 of Mathematica, I have used this (it's almost the same as Max's answer): token = OAuthSigning`OAuthAuthentication[ "ConsumerKey" -> "consumerkey", "ConsumerSecret" -> "consumersecret", "RequestEndpoint" -> "https://api.twitter.com/oauth/request_token", "AuthorizeEndpoint" -> "https://api.twitter.com/oauth/authorize", "...


4

Here's an elaboration on my suggestion. More information on why I'm doing what I'm doing is here: Creating a custom web API ServiceConnection First open the paclet: SystemOpen @ PacletFind["*_GoogleCalendar"][[1]]["Location"] Go into the GoogleCalendar.m file and make the following changes: Add "RawPosts"->{"RawCalendarInsert"} and "Posts"->{"...


3

Ahh, I figured it out! Thanks for your help, and thanks to the person who helped me with my last question (Want to convert a string to a SHA512 Base64 value), cause that also helped me find the solution. You were right, it needed to be encoded to Base-64. The new function for this is given below: HmacSHA512Base64[message_, key_] := Module[ {blocksize =...


3

This is much easier to do as of the recently released version 11.3.0: BaseEncode[Hash["333", "SHA512", "ByteArray"]] (* "XjFVd0052XxfnhfBCMKz4EhaQ64069GW9hpvi/cy73GknlcQWUz8c5HbEU7fmfXaPtlu8dbKXlmOhfkb1B5+6w==" *)


3

According to this, the MD5 scheme uses "an Apache-specific algorithm using an iterated (1,000 times) MD5 digest of various combinations of a random 32-bit salt and the password. See the APR source file apr_md5.c for the details of the algorithm." While that could in principle be implemented, it's much easier to generate the SHA1-digest form: htpasswdsha[...


1

Thanks for your reply. Indeed, the function hmacFnew[] from that answers works perfectly on Mathematica v11.3- confirmed and tested. hmacFnew[method_, message_, key_] := Module[{dkey, dmsg, opad, ipad, blocksize}, blocksize = If[method === "SHA384" || method === "SHA512", 128, 64]; {dkey, dmsg} = StringToByteArray /@ {key, message};...


1

The answer is in their FAQ: https://www.wolfram.com/cdf/faq/ Why can't I edit text in CDF Player? CDF Player is intended as a deployment option. If you want to edit or create applications or documents, then you need Mathematica or any other CDF content creator, such as Wolfram|Alpha.


Only top voted, non community-wiki answers of a minimum length are eligible