We're using R2012a, in case that plays into your answer.
Our project's source fileset has been backed up at intervals, but despite that, at least one m-file has gone missing from the current fileset and all backups. A p-file exists. I have read the Community posts about de-obfuscation and totally get the reason for the absence of such a function as long as the MathWorks has sole access to the encryption key(s).
My question is, why isn't there a form of pcode that allows the caller to specify a key or key pair, so that those who have been given a key by the code's developer can analyze the pcode and at least partially restore the source code and symbol definitions? If that had been available, I'm sure my PI would have used it, and our task of restoring the function would be much easier.
Doug

 採用された回答

Jan
Jan 2015 年 7 月 15 日
編集済み: Jan 2015 年 7 月 15 日

0 投票

It is very easy to create such files with a specified key: Simply use a zip or 7z format with an encryption key. Then you can restore the original file even with comments and without loosing any information.
A user provided key inside the P-file is not useful: If the key is a part of the file, it does not matter if Mathworks or the user provides it. In both cases it can be extracted by the same trivial method.
Nothing is as reliable as a working backup system. User provided keys for a proprietary file format with a high degree of obfuscation are not a trustworthy system for a file recovery.

3 件のコメント

Steven Lord
Steven Lord 2015 年 7 月 15 日
To add to what Jan said, there is functionality in MATLAB itself to interface with source control systems like Git and Subversion. Source control systems offer more benefits than just keeping a backup; it lets you track history (in case you need to perform some archeology to determine when and/or why a bug was introduced) and facilitates collaborative development by helping you merge your changes with your colleagues' changes.
Michael Shribak
Michael Shribak 2015 年 7 月 16 日
(N.b., this is Doug talking again, speaking for himself and not for the account holder.) I get all of this -- as I said, I read the posts on this topic already. (Thanks BTW for patiently repeating yourselves.) I agree. BEGIN WHINE Unfortunately, you can't force every overworked grad student or postdoc to follow source control or backup protocols. Since I just joined the project in question, I wasn't around to insist on their doing so. I was just wishing for a world in which a late arrival like myself could rescue a source file (m-file) lost due to the lack of these controls. END WHINE --Doug
Doug MacDonald
Doug MacDonald 2015 年 7 月 16 日
I'm the poster of this question and will use my own account henceforth! (Honestly, I forgot I had one...) Regards, Doug

サインインしてコメントする。

その他の回答 (0 件)

カテゴリ

ヘルプ センター および File ExchangeProgramming についてさらに検索

製品

質問済み:

2015 年 7 月 14 日

コメント済み:

2015 年 7 月 16 日

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by