Tinycal api4/26/2023 Once there, I searched for Google Calendar and here were some of the top results: My first step with any Mac software is to go to, the best repository of Mac software, shareware and freeware online, in my experience. Rather than just tell you the name of the neat little application that solves the problem, I thought it would be more useful to show you how I dug around and found it, since this wasn’t something I know off the top of my head… keytool -import -file selfsigned.pem -alias server -keystore server.This is an example of a “resource discovery problem” (I can use these big fancy phrases because, with apologies to Duck’s Breath Mystery Theater, I have a master’s degree… in science). To create the key store with a PEM format certificate, you can write your own code using CertificateFactory, or just import it with keytool from the JDK (keytool won't work for a "key entry", but is just fine for a "trusted entry"). KeyStore.load(trustStore, trustStorePassword) Here's an example of loading the key store: KeyStore keyStore = KeyStore.getInstance(KeyStore.getDefaultType()) If you need help creating the key store, please comment. SSLContext ctx = SSLContext.getInstance("TLS") Ĭtx.init(null, tmf.getTrustManagers(), null) TrustManagerFactory.getInstance(TrustManagerFactory.getDefaultAlgorithm()) Here's a sketch of how to initialize it: /* Load the keyStore that includes self-signed cert as a "trusted" entry. You'll want to create one SSLSocketFactory and keep it around. HttpsURLConnection conn = (HttpsURLConnection)url.openConnection() In addition you could also change the url to reflect the jQuery major number if you wanted to make sure that the latest Major version of the jQuery libraries were loaded: įinally, if you don't want to use Google and would prefer jQuery you could use the following source path (keep in mind that jQuery doesn't support SSL connections): Ĭreate an SSLSocket factory yourself, and set it on the HttpsURLConnection before connecting. Some suggestions have been made to reduce the complexity of the code by removing the HTTP and HTTPS and simply use the following syntax: If you have a mixture of secure and insecure pages on your site you might want to dynamically change the Google source to avoid the usual warning you see when loading insecure content in a secure page: Up to this point I haven't been disappointed with using Google and will continue this configuration until it makes sense not to. I understand that I place a portion of trust on Google to serve the correct script file, and to be online and available. No sense consuming 18k per user session if the visitor can get the same file elsewhere. Third: My web hosting company charges me for the bandwidth used. Pre-cached content usually means faster load times for the visitor. Second: Many people choose to have JQuery hosted on Google, so when a visitor comes to my site they may already have the JQuery script in their local cache. I didn't go with the jsapi method since I don't leverage any other Google API's, however if that ever changed then I would consider it.įirst: The Google api servers are distributed across the world instead of my single server location: Closer servers usually means faster response times for the visitor. Without a doubt I choose to have JQuery served by Google API servers.
0 Comments
Leave a Reply.AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |