100% found this document useful (1 vote)
1K views

MPBinX Guide Reference Mastercam 2017

The document provides guidelines for using MPBinX to encrypt parts of Mastercam post processor files. MPBinX removes code from the post file, encrypts it into a separate binary file, and keys the encrypted code to a specific SIM number, SIM type, or software license number. Users can encrypt posts for a specific SIM type so the post will run on any machine with that SIM type, or for specific SIM/license numbers so the post only runs on machines with those numbers. The document explains how to identify the code segments to encrypt using start and end tags, and how MPBinX processes and outputs encrypted post and binary files.

Uploaded by

eltklas
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
100% found this document useful (1 vote)
1K views

MPBinX Guide Reference Mastercam 2017

The document provides guidelines for using MPBinX to encrypt parts of Mastercam post processor files. MPBinX removes code from the post file, encrypts it into a separate binary file, and keys the encrypted code to a specific SIM number, SIM type, or software license number. Users can encrypt posts for a specific SIM type so the post will run on any machine with that SIM type, or for specific SIM/license numbers so the post only runs on machines with those numbers. The document explains how to identify the code segments to encrypt using start and end tags, and how MPBinX processes and outputs encrypted post and binary files.

Uploaded by

eltklas
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 12

MPBinX User’s Guide

Quick Start

The MPBinX C-Hook is used to convert and encrypt part of an ASCII


post processor (.PST) file. This process lets Resellers and advanced
users protect their posts from being edited or viewed by unauthorized
users.
Mastercam protects the post by:
 Removing a block of text from the post file.
 Converting the removed text into a encrypted binary file
(*.PSB).
 Keying the protected post to a particular SIM number or type of
SIM, or (begining with Mastercam 2017) a software license.
In addition, Resellers have the option of adding password protection to
the encrypted post to restrict updating with the UpdatePost C-Hook.
Since Mastercam X5, MPBinX can also be used to encrypt Mastercam
Simulation (“MachSim”) machine definitions and related files.
Beginning with Mastercam 2017, MPBinX supports software licensing.
In addition to HASPs, you can now bin a post to a software license
number.
This guide has the following sections:
 Preparing a post for encryption
 Encrypting a post with MPBinX
 Guidelines for encrypting a post
 Re-encrypting a .PSB file
 Locking posts from being updated
 Encrypting machine definitions for Mastercam Simulation
2 • REV: MAY 2016

Preparing a post for encryption


Before running MPBinX, follow these steps to identify the content in your post that you
Quick Start
want encrypted.
1 Make a backup copy of your original post.

2 Open the post (.PST or .PSM) file in a text editor.

3 Insert [STARTBIN] where code encryption should start.

4 Insert [ENDBIN] where code encryption should stop.

5 Save the file.


Make sure you follow these guidelines:
 The [STARTBIN] and [ENDBIN] keywords must each be on a separate line and
start in the first column.
 The keywords must not appear inside a postblock.
 The keywords cannot be nested. You can, however, have multiple sets of
unnested keywords.
 If the keywords appear in comments (after the # symbol), MPBinX ignores them.
 If the keywords do not occur in ordered, matched pairs, MPBinX ignores them.

Notes:
 During encryption, MPBinX removes all code between [STARTBIN] and
[ENDBIN]from the original post file. The resulting .PSB file contains the
removed code in encrypted form.
 You can select a .PSB that has already been encrypted if its associated .PST file is
also present. Simply insert new [STARTBIN] and [ENDBIN] tags in the .PST file.
 You can delimit any amount of text—from one line to the entire post processor
file—with [STARTBIN] and [ENDBIN]. However, we recommend that you leave
whatever code the user needs to make minor modifications without your help.
MPBINX USER’S GUIDE / Encrypting a post with MPBinX • 3

Encrypting a post with MPBinX


Follow these steps to encrypt a post:
Quick Start
1 Choose Run Add-In from the Home ribbon bar (or press Alt+C).

2 Select the mpbinX.dll C-Hook. The dialog box displays:

3 In the Post processor filename field, select the .PST or .PSM file to be encrypted.

4 Select the Target directory. MPBinX writes the encrypted post and log files here.

5 In the Options and SIM type access selection boxes, choose the level of
protection. You can encrypt the post in either of two ways:
 To run only on specific SIM or software license numbers.
 To run only on specific types of SIMs. (See the guidelines below.)
6 To prevent the post from being updated:

a Click Update Post Locking.

b Enter password-protection information (see Locking posts from being


updated on page 10).

7 Click OK to process the files and close the dialog box, or click Apply to process
the selected files and leave the dialog box open.
8 Click View log file to review the results. MPBinX writes the log file to the target
directory as mpbinx.log.
9 Distribute the new .PST and .PSB files to the end user. Save the original post file
(the one you chose in Step 3) so that you can create new .PSB files, as needed.
4 • REV: MAY 2016

Pay attention to these notes:


 When removing text delimited by [STARTBIN] and [ENDBIN], MPBinX leaves
the [STARTBIN] line in the final .PST file. This [STARTBIN] tag marks where
MP begins reading from the encrypted .PSB file.
 If multiple [STARTBIN] and [ENDBIN] sets reside in the post, MPBinX saves Quick Start
only the first set.
 MPBinX removes the [ENDBIN] line from the converted post. The [ENDBIN]
keyword will not appear in the .PST or .PSB file.
 If you run a post with the extension .PSM, MPBinX ignores the words
[STARTBIN] and [ENDBIN].
 Select Always allow post to run on dealer SIM to override all other settings for
SIM types and to allow the post to run with any dealer SIM.
See Guidelines for encrypting a post on page 5 to learn more about any of the following
topics:
 Selecting an encryption method
 Storing SIM or license numbers in a text file
 Typing SIM or license numbers in the window

How MPBinX processes files


Types of input files:
.PSM—The .PST and .PSB files are assumed not to exist if a .PSM file is selected.
Mastercam processes the file without checking if a PST or PSB file already exists.
.PST—Mastercam checks to see if a .PSB file already exists. If so, it re-processes the files.
Otherwise, it generates a new .PSB and .PST file. If there is a .PSM file, it is ignored.
.PSB—Mastercam assumes that this file is being re-processed and looks for the matching
.PST file in the same folder. If there is a .PSM file, it is ignored. (See Re-encrypting a .PSB
file on page 9 to learn more.)
The output files are always the .PST and .PSB files in the directory specified as the Target
directory. Mastercam appends to each filename an underscore and the SIM number that
it was processed for to make it easy to identify. For example:
Processing MPFAN.PSM for the SIM number 12345 results in:
 MPFAN_12345.PST
 MPFAN_12345.PSB
Choose the Do not append SIM number to processed post filename option to prevent
the SIM number from being appended to the filename. This is only valid for the first file if
multiple SIM numbers are being processed.
MPBINX USER’S GUIDE / Guidelines for encrypting a post • 5

Guidelines for encrypting a post

Selecting an encryption method Quick Start

Each encryption method has advantages and disadvantages:


Encrypting posts for a specific SIM type—The advantage is that only one post binary file
needs to be made. The post will run regardless of the SIM number. The disadvantage is
that, even though users can’t read or modify the post, they can share the post with other
Mastercam users.
 When encrypting for SIM types, select the desired categories from the SIM type
access selection options:

Encrypting posts for specific SIM numbers or software license numbers—The advantage
is that the post binary file will run only on a computer with one of the specified SIM
numbers or software licenses. Users cannot read or modify the post, nor can they share
the post with other users. The disadvantage is that a separate post binary file must be
made for each specified SIM or software license. When the original post is changed, new
binary files must be made for each user.
MPBinX supports three types of license numbers:
 SIMs (HASPs)
 Software license container number (X9 only)
 Software license numbers (beginning with Mastercam 2017)
When encrypting by SIM number or software license, use the SIM number(s) window in
to list all of the valid SIMs or software licenses for which the post will run. When MPBinX
processes the post, it generates a separate output file for each number.
See Binning a post to a software license number on page 7 to learn more about software
licensing.
6 • REV: MAY 2016

Storing SIM or license numbers in a text file


You can store a list of SIM or license numbers in a text file, which lets you easily recall
them for later encryption jobs. Write each SIM or license number as a separate line in the
text file.
Quick Start
The default extension for the file is .sim, but you can use any extension you like.
Click the file cabinet to select the file:

Then click Load.


 If there are already SIM or license numbers listed in the MPBinX dialog box, they
will be overwritten.
 You can add new entries by typing them on a new line in the window.
 Click Save to store your changes to the file.

Typing SIM or license numbers in the window


You can type SIM or software license numbers directly into the SIM number(s) pane of
the Mpbinx dialog box. Press [Enter] after typing each number. Use the following keys to
edit the list:
 [Up] and [Down] arrow keys move between fields.
 [F3] compresses the list to remove blank lines.
 [Backspace] deletes the current character.
 [Delete] clears an entire line.
 [Alt+U] restores a line to its pre-edited state.

TIP: You can mix-and-match SIM numbers and software license numbers in the
same list or text file.
MPBINX USER’S GUIDE / Guidelines for encrypting a post • 7

Binning a post to a software license number


Mastercam X9 introduced the ability to bin a post to a software license. In most respects,
this works exactly the same as binning to a hardware SIM: simply enter the software
license number instead of the SIM number.
Quick Start
However, there is one big difference between X9 and Mastercam 2017:
 In X9, you bin the post to the CodeMeter container number.
 In Mastercam 2017, you bin the post to the license number.
You can find the proper numbers in the CodeMeter Web Admin page. The following
picture shows you these numbers. For Mastercam 2017, make sure you use the license
number, not the customer ID number.

 If you are binning to the container number in X9, only use the 7 digits after the
dash.
 If you are binning to the license number in Mastercam 2017, do not include the
W—only the 5-digit number.
8 • REV: MAY 2016

If you are using the most recent version of CodeMeter, the interface will be different. The
screen will look like this:

Quick Start

NOTE: If you are binning to an Eval license, please be aware that if the customer
purchases the product, the license number WILL change and the post will need to
be binned again!
Similarly, if an Eval period is extended with a new license, the license number will
also change and the post will need to be binned again.

Please refer to Mastercam’s Software Licensing Guide to learn more about software
licensing and CodeMeter containers.
MPBINX USER’S GUIDE / Re-encrypting a .PSB file • 9

Re-encrypting a .PSB file


You can re-encrypt a .PSB that has already been encrypted if its associated .PST file is
Quick Start
also present. Simply insert new [STARTBIN] and [ENDBIN] keys in the .PST file.
If you are processing a .PSB file that has already been encrypted, it is not possible to
select a SIM type if it was not selected when the post was last encrypted. For example, if
Educational was not selected when a post was originally encrypted, reprocessing the
.PSB file and selecting Educational does not enable the new post to run on an
Educational SIM. A message is generated in the log file indicating that the selection was
disabled in the new post.
Mastercam will only process a .PSB file if it was encrypted to run on any SIM number and
at least one SIM type access selection matches the SIM you have on your local
workstation.
10 • REV: MAY 2016

Locking posts from being updated


In addition to encrypting the post, MPBinX also lets you lock it from being updated in the
Quick Start
future with the UpdatePost utility. In order for the post to be updated, a password needs
to be entered that is set when you encrypt the post.

NOTE: This option is only available to Resellers who are running MPBinX on a
Dealer SIM.

Follow these steps:


1 Run the MPBinX C-Hook.

2 Click the Update Post Locking button.

The following dialog box opens:

3 Click Enable to activate the other dialog box fields.

4 Enter and confirm the desired password into the Password Protection fields.
By default, the only SIM or software license authorized to update the post with the
UpdatePost C-Hook is the one displayed in Your SIM Number. You can type additional
authorized SIMs in the Additional SIMs Allowed box. Or, you can load a list of SIM
numbers from a text file. See Storing SIM or license numbers in a text file on page 6 to
learn more.
MPBINX USER’S GUIDE / Locking posts from being updated • 11

Quick Start
12 • REV: MAY 2016

Encrypting machine definitions for


Mastercam Simulation
Quick Start

MPBinX can also be used to encrypt the machine definition files used for Mastercam
Simulation. You can choose to encrypt either the XML machine definition file, PRM files,
the STL files that store the component models, or any combination.
To encrypt machine defintion files, follow the same process as Encrypting a post with
MPBinX on page 3 and select the desired machine definition files.
While PST files that are encrypted need to be prepared with [STARTBIN] and [ENDBIN]
tags, no such tags or other preparation are needed for machine definition files. For each
selected file, the entire file is encrypted.
The STL files might be either ASCII files or binary files. MPBinX will automatically detect
the file type and process it appropriately. Because of this, you typically do not need to
select the binary files option:

Encrypted machine definition files will have a modifed extension that can be used to
identify them:
 Text files that are encrypted will have -TBIN appended to their extension. For
example, Integrex-MarkIV.XML will be encrypted as Integrex-
MarkIV.XML-TBIN.
 Binary files that are encrypted will have -BIN appended to their extension. For
example, a binary STL file such as TURRET.STL will be encrypted as
TURRET.STL-BIN.
 STL files in ASCII format will have the -TBIN extension.
Typically the goal of encrypting the files is to prevent them from being copied and
modified, instead of restricting their use to a specific user. In that case, enable all the SIM
types when selecting the encrption method:

You might also like