Components All New MacOS Windows Linux iOS
Examples Mac & Win Server Client Guides Statistic FMM Blog Deprecated Old

MBS FileMaker Plugin Example Databases

RSA Sign and Verify

All examples are included with download of MBS FileMaker Plugin.

RSA Sign and Verify.fmp12

Overview
Tables1
Relationships0
Layouts1
Scripts4
Value Lists0
Custom Functions0
Custom Menus33
File Options
Default custom menu set[Standard FileMaker Menus]
When opening file
Minimum allowed version12.0
Login usingAccount Name; Account= Admin
Allow user to save passwordOff
Require iOS passcodeOff
Switch to layoutOff
Hide all toolbarsOff
Script triggers
OnFirstWindowOpenOff
OnLastWindowCloseOff
OnWindowOpenOff
OnWindowCloseOff
OnFileAVPlayerChangeOff
Thumbnail Settings
Generate ThumbnailsOn; Temporary

 

Tables

Table Name
Statistics
Occurrences in Relationship Graph
Table
5 fields defined, 1 record
Table

Fields

Table Name: Table - 5 Fields
Field NameTypeOptionsCommentsOn LayoutsIn RelationshipsIn ScriptsIn Value Lists
PrivateKeyNormal, TextAuto-Enter:
  • Allow editing
Validation:
  • Only during data entry
Storage:
  • Repetitions: 1
  • Indexing: None
  • Automatically create indexes as needed
  • Index Language: German
      PublicKeyNormal, TextAuto-Enter:
      • Allow editing
      Validation:
      • Only during data entry
      Storage:
      • Repetitions: 1
      • Indexing: None
      • Automatically create indexes as needed
      • Index Language: German
          Text to SignNormal, TextAuto-Enter:
          • Allow editing
          Validation:
          • Only during data entry
          Storage:
          • Repetitions: 1
          • Indexing: None
          • Automatically create indexes as needed
          • Index Language: German
              SignatureNormal, TextAuto-Enter:
              • Allow editing
              Validation:
              • Only during data entry
              Storage:
              • Repetitions: 1
              • Indexing: None
              • Automatically create indexes as needed
              • Index Language: German
                  AlgorithmNormal, TextAuto-Enter:
                  • Allow editing
                  Validation:
                  • Only during data entry
                  Storage:
                  • Repetitions: 1
                  • Indexing: None
                  • Automatically create indexes as needed
                  • Index Language: German

                      Layout Objects: Table

                      Regular Fields

                      Field Name: Table::PrivateKey
                      Field PropertiesCoordinatesField FormatField BehaviorQuick Find
                      • Top: 24 pt
                      • Left: 138 pt
                      • Bottom: 224 pt
                      • Right: 391 pt
                      • Anchoring: Left, Top
                      Field Format:
                      • Edit Box
                      Field Behavior:
                      • Allow field to be entered: In Find mode, In Browse mode
                      • Touch keyboard type: System Default
                      • Go to next field using: Tab key
                      Yes

                      Field Name: Table::PublicKey
                      Field PropertiesCoordinatesField FormatField BehaviorQuick Find
                      • Top: 24 pt
                      • Left: 462 pt
                      • Bottom: 224 pt
                      • Right: 715 pt
                      • Anchoring: Left, Top
                      Field Format:
                      • Edit Box
                      Field Behavior:
                      • Allow field to be entered: In Find mode, In Browse mode
                      • Touch keyboard type: System Default
                      • Go to next field using: Tab key
                      Yes

                      Field Name: Table::Text to Sign
                      Field PropertiesCoordinatesField FormatField BehaviorQuick Find
                      • Top: 228 pt
                      • Left: 138 pt
                      • Bottom: 362 pt
                      • Right: 391 pt
                      • Anchoring: Left, Top
                      Field Format:
                      • Edit Box
                      Field Behavior:
                      • Allow field to be entered: In Find mode, In Browse mode
                      • Touch keyboard type: System Default
                      • Go to next field using: Tab key
                      Yes

                      Field Name: Table::Signature
                      Field PropertiesCoordinatesField FormatField BehaviorQuick Find
                      • Top: 228 pt
                      • Left: 462 pt
                      • Bottom: 362 pt
                      • Right: 715 pt
                      • Anchoring: Left, Top
                      Field Format:
                      • Edit Box
                      Field Behavior:
                      • Allow field to be entered: In Find mode, In Browse mode
                      • Touch keyboard type: System Default
                      • Go to next field using: Tab key
                      Yes

                      Field Name: Table::Algorithm
                      Field PropertiesCoordinatesField FormatField BehaviorQuick Find
                      • Top: 366 pt
                      • Left: 138 pt
                      • Bottom: 380 pt
                      • Right: 391 pt
                      • Anchoring: Left, Top
                      Field Format:
                      • Edit Box
                      Field Behavior:
                      • Allow field to be entered: In Find mode, In Browse mode
                      • Touch keyboard type: System Default
                      • Go to next field using: Tab key
                      Yes

                      Group Buttons

                      Button PropertiesCoordinatesScript/Script Step
                        Type:
                      • Text: Generate Keys
                        Additional Properties:
                      • Change to hand cursor over button
                      • Rectangular
                      • Top: 48 pt
                      • Left: 732 pt
                      • Bottom: 73 pt
                      • Right: 835 pt
                      • Anchoring: Left, Top
                      Perform Script [ “GenerateKeys” ]

                      Scripts:


                      Button PropertiesCoordinatesScript/Script Step
                        Type:
                      • Text: Sign
                        Additional Properties:
                      • Change to hand cursor over button
                      • Rectangular
                      • Top: 228 pt
                      • Left: 732 pt
                      • Bottom: 253 pt
                      • Right: 835 pt
                      • Anchoring: Left, Top
                      Perform Script [ “Sign” ]

                      Scripts:


                      Button PropertiesCoordinatesScript/Script Step
                        Type:
                      • Text: Verify
                        Additional Properties:
                      • Change to hand cursor over button
                      • Rectangular
                      • Top: 258 pt
                      • Left: 732 pt
                      • Bottom: 283 pt
                      • Right: 835 pt
                      • Anchoring: Left, Top
                      Perform Script [ “Verify” ]

                      Scripts:


                      Script Hierarchy

                      GenerateKeys
                      Sign
                      Verify
                      Clear

                      Next Script: [Sign]
                      Script NameGenerateKeys
                      Run script with full access privilegesOff
                      Include In MenuYes
                      Layouts that use this script
                      Scripts that use this script
                        Script Definition
                        Script Steps
                        • Set Variable [ $privateKey; Value:MBS( "RSA.GeneratePrivateKey") ]
                        • Set Variable [ $publickey; Value:MBS( "RSA.GetPublicKey"; "text"; $privateKey; "UTF-8") ]
                        • Set Field [ Table::PrivateKey; $privateKey ]
                        • Set Field [ Table::PublicKey; $publicKey ]
                        Fields used in this script
                        Scripts used in this script
                          Layouts used in this script
                            Tables used in this script
                            Table occurrences used by this script
                            Custom Functions used by this script
                              Custom menu set used by this script

                                Previous Script: [GenerateKeys]Next Script: [Verify]
                                Script NameSign
                                Run script with full access privilegesOff
                                Include In MenuYes
                                Layouts that use this script
                                Scripts that use this script
                                  Script Definition
                                  Script Steps
                                  • Set Field [ Table::Signature; MBS( "RSA.Sign"; Table::Algorithm; "Text"; Table::Text to Sign; "UTF8"; "text"; Table::PrivateKey; "UTF8"; ""; ""; ""; "hex"; "" ) ]
                                  Fields used in this script
                                  Scripts used in this script
                                    Layouts used in this script
                                      Tables used in this script
                                      Table occurrences used by this script
                                      Custom Functions used by this script
                                        Custom menu set used by this script

                                          Previous Script: [Sign]Next Script: [Clear]
                                          Script NameVerify
                                          Run script with full access privilegesOff
                                          Include In MenuYes
                                          Layouts that use this script
                                          Scripts that use this script
                                            Script Definition
                                            Script Steps
                                            • Set Variable [ $r; Value:MBS( "RSA.Verify"; Table::Algorithm; "Text"; Table::Text to Sign; "UTF8"; "Text"; Table::PublicKey; "UTF8"; "Hex"; Table::Signature ) ]
                                            • If [ $r = 1 ]
                                            • Show Custom Dialog [ Message: "Signature valid"; Default Button: “OK”, Commit: “Yes”; Button 2: “Cancel”, Commit: “No” ]
                                            • Else If [ $r = 0 ]
                                            • Show Custom Dialog [ Message: "Signature invalid"; Default Button: “OK”, Commit: “Yes”; Button 2: “Cancel”, Commit: “No” ]
                                            • Else
                                            • Show Custom Dialog [ Title: "Error"; Message: MBS("Text.RemovePrefix"; $r; "[MBS] "); Default Button: “OK”, Commit: “Yes”; Button 2: “Cancel”, Commit: “No” ]
                                            • End If
                                            Fields used in this script
                                            Scripts used in this script
                                              Layouts used in this script
                                                Tables used in this script
                                                Table occurrences used by this script
                                                Custom Functions used by this script
                                                  Custom menu set used by this script

                                                    Previous Script: [Verify]
                                                    Script NameClear
                                                    Run script with full access privilegesOff
                                                    Include In MenuYes
                                                    Layouts that use this script
                                                      Scripts that use this script
                                                        Script Definition
                                                        Script Steps
                                                        • Set Field [ Table::PrivateKey; "" ]
                                                        • Set Field [ Table::PublicKey; "" ]
                                                        • Set Field [ Table::Signature; "" ]
                                                        Fields used in this script
                                                        Scripts used in this script
                                                          Layouts used in this script
                                                            Tables used in this script
                                                            Table occurrences used by this script
                                                            Custom Functions used by this script
                                                              Custom menu set used by this script

                                                                Download example: RSA Sign and Verify

                                                                Used functions: