ScriptMaster

From 360Works Product Documentation Wiki
(Difference between revisions)
Jump to: navigation, search
(FileMaker 18 Changes)
(ScriptMaster changes as of June 2023)
 
(5 intermediate revisions by one user not shown)
Line 1: Line 1:
 
[http://360works.com/scriptmaster/ ScriptMaster] is a free, general purpose plug-in. Extended documentation [http://static.360works.com/plugins/SCRIPTMASTERPLUGIN/documentation.html here].
 
[http://360works.com/scriptmaster/ ScriptMaster] is a free, general purpose plug-in. Extended documentation [http://static.360works.com/plugins/SCRIPTMASTERPLUGIN/documentation.html here].
  
==Mac OS Catalina Changes==
+
==ScriptMaster changes as of June 2023==
Mac OS Catalina (10.15 and later) have introduced a security requirement that requires all executable software to be Notarized by Apple in order to run. Notarization is fairly involved, and is well documented on Apple's developer pages.
+
Due to increasingly restrictive signing and notarization requirements, ScriptMaster Advanced will no longer be offered. The access to clipboard and FileMaker SQL engine features of ScriptMaster Advanced are now included in the ScriptMaster plugin for free. Custom plugin generation is now offered as a service at our current hourly support rate. If you would like to have us generate a custom plugin for you, please contact us at support@360Works.com.
  
This provides a good outline of Notarization:
+
<b>Legacy documentation can be found [[ScriptMaster legacy information|here]]</b>
[https://developer.apple.com/documentation/xcode/notarizing_macos_software_before_distribution Notarizing Software Before Distribution]
+
  
This shows how you can use the command line tools to notarize your plugins after you have made them:
+
==FAQ and Troubleshooting==
[https://developer.apple.com/documentation/xcode/notarizing_macos_software_before_distribution/customizing_the_notarization_workflow Customizing Notarization Workflow]
+
 
+
Alternatively, if you want to run a plugin on Mac without notarizing it, you can disable the Mac OS Gatekeeper.  You can disable Gatekeeper using the instructions here:
+
[https://help.apple.com/xcode/mac/10.2/index.html?localePath=en.lproj#/dev9b7736b0e Enable/Disable Gatekeeper]
+
 
+
This does pose a security risk, and if you do decide to do this, it is best if you:
+
 
+
* Disable Gatekeeper
+
* Launch the plugin, this will "whitelist" it
+
* Re-enable Gatekeeper
+
 
+
Whitelisting the plugin will allow it to run after you have turned Gatekeeper back on.
+
 
+
==Requirements starting in FileMaker 18==
+
FileMaker 18 requires that all plugins come with a signature, which indicates that the software is valid, unchanged, and made by a certain developer. The default store version of ScriptMaster, which you can download at this page [https://360works.com/scriptmaster/ here], comes already signed by 360Works. So if you are strictly using ScriptMaster to register modules and execute the RegisterGroovy or the EvaluateGroovy functionalities of the plugin, you can use the store version without issues. However, if you are using ScriptMaster to generate your own plugins, you will need to generate them with an unsigned version of the ScriptMaster plugin, then sign them with your own code signing certificate.
+
 
+
The reason for needing an unsigned version of ScriptMaster to generate plugins, is that ScriptMaster makes plugins by essentially copying itself into the new plugin, along with the functions you have written.  If ScriptMaster is signed before this copy happens, it will carry the signature with it.  This is unfortunate, because the newly generated plugin does not match the ScriptMaster plugin exactly, and so the signature it has carried with it is now invalid, and the plugin will not be loaded by FileMaker.
+
 
+
To get around this issue, generated plugins should be created using an unsigned version of ScriptMaster, so that this invalid signature does not get written to the newly generated plugin.
+
 
+
To begin, you'll need to use the unsigned version of ScriptMaster, which you can download at this link [https://s3.amazonaws.com/com.prosc.public/ScriptMasterUnsigned/360Works+ScriptMaster-UNSIGNED.zip here].  Create your plugins using this version of ScriptMaster.  Plugins created in this fashion will work in FileMaker Pro, but your users will see a warning message about "Could not verify the identity of this plugin".  If you are ok with this warning you may want to stop here.
+
 
+
'''Note:''' Unsigned plugins will not be initialize in FileMaker Server 18 or the Web Publishing Engine.  Plugins must be signed to work in these components.
+
 
+
<b>Note:</b> Starting in FileMaker Pro 19.3, the option to "allow anyway" has been removed so unsigned plugins will behave just like in FileMaker Server, they will not show up in Preferences and will not enable. This means that you will not be able to use the unsigned version of ScriptMaster to generate plugins and you will have to sign your custom plugins if you want to use them in this version or later.
+
 
+
==Signing Generated Plugins==
+
===On Mac===
+
You will need two things:
+
* A code signing certificate
+
* The codesign utility installed (comes with Xcode command line tools)
+
 
+
You will need to enroll in an Apple Developer Account, and set up that account in Xcode on your machine.  This should automatically install the codesign utility, and the certificates you need to sign plugins.  Troi has some additional information on this [https://www.troi.com/plug-in-development/code-signing-filemaker-plugins/ here].
+
 
+
Once that is set up, you can sign your plugins by running the command:
+
 
+
: codesign -s "Your Developer Name" /path/to/MyGeneratedPlugin.fmplugin
+
 
+
You can validate the signature by running:
+
 
+
: codesign -v --verbose /path/to/MyGeneratedPlugin.fmplugin
+
 
+
===On Windows===
+
On Windows, you will need Microsoft Visual Studio downloaded and installed. Both Troi and FM Plugins have simple writeups of this process [https://www.troi.com/plug-in-development/code-signing-filemaker-plugins/ here] and [http://fmplugins.idma.nz/index.php?title=Code_Signing here] respectively. You will need to acquire a code certificate from a Certificate Authority, such as [https://www.comodo.com/ Comodo], as the Apple certificate will not work on Windows. After receiving and preparing your certificate, you'll need to open your generated plugin in Visual Studio, and use the signtool.exe in the Visual Studio Command Prompt.  I have also used PowerShell to run this command with good results:
+
 
+
: signtool sign /f "C:\Users\acme\your-code-sign2018.pfx" /p YOUR_PASSFRASE_HERE /tr http://timestamp.comodoca.com "C:\Users\acme\Desktop\PluginName.fmx64
+
 
+
 
+
==Troubleshooting==
+
 
+
==Deployment and installation==
+
 
===Will ScriptMaster run on FileMaker Server?===
 
===Will ScriptMaster run on FileMaker Server?===
 
Yes. ScriptMaster will run in all three possible plugin configurations: FileMaker Client, FileMaker Server, and FileMaker Web Publishing Engine. See the [[Plugin installation]] page for information on where to put the plugin for these configurations.
 
Yes. ScriptMaster will run in all three possible plugin configurations: FileMaker Client, FileMaker Server, and FileMaker Web Publishing Engine. See the [[Plugin installation]] page for information on where to put the plugin for these configurations.
  
 
+
===When using Select File module I get spinning beach ball (Mac)===
 
+
===Will Generated Plugins run on FileMaker Server?===
+
Yes, but in server 18 they will only initialize if they are signed.  This is also the case for FileMaker Web Publishing Engine.
+
 
+
 
+
 
+
===Changing Log Location===
+
To specify the location to which ScriptMaster writes log files, create a file called "loglocation". The contents of the file should contain the path you want to use to store log files. Place the file in the appropriate location:
+
* OS X: /Library/Application Support/360FmKit
+
*All Windows: C:\360Works\loglocation
+
 
+
=== When using Select File module I get spinning beach ball (Mac)===
+
 
This sometimes happens when you use the Select File module with the Allow User Abort FM script step set to OFF. Setting this value to ON, allows the Select File function to work smoothly.
 
This sometimes happens when you use the Select File module with the Allow User Abort FM script step set to OFF. Setting this value to ON, allows the Select File function to work smoothly.
 
==Using Get( InstalledFMPlugins ) with custom plugins generated by ScriptMaster==
 
Due to a bug in FileMaker, the Get( InstalledFMPlugins ) function will return the version number of the ScriptMaster plugin used to generate the custom plugin instead of the custom plugin's version number. You should use the included "xVersion" function that comes with all custom built ScriptMaster plugins instead when trying to determine which version of your custom plugin is installed.
 

Latest revision as of 20:56, 2 June 2023

ScriptMaster is a free, general purpose plug-in. Extended documentation here.

Contents

[edit] ScriptMaster changes as of June 2023

Due to increasingly restrictive signing and notarization requirements, ScriptMaster Advanced will no longer be offered. The access to clipboard and FileMaker SQL engine features of ScriptMaster Advanced are now included in the ScriptMaster plugin for free. Custom plugin generation is now offered as a service at our current hourly support rate. If you would like to have us generate a custom plugin for you, please contact us at support@360Works.com.

Legacy documentation can be found here

[edit] FAQ and Troubleshooting

[edit] Will ScriptMaster run on FileMaker Server?

Yes. ScriptMaster will run in all three possible plugin configurations: FileMaker Client, FileMaker Server, and FileMaker Web Publishing Engine. See the Plugin installation page for information on where to put the plugin for these configurations.

[edit] When using Select File module I get spinning beach ball (Mac)

This sometimes happens when you use the Select File module with the Allow User Abort FM script step set to OFF. Setting this value to ON, allows the Select File function to work smoothly.

Personal tools
Namespaces

Variants
Actions
Plug-in Products
Other Products
Navigation
Toolbox