Issues With Third Party Library as Part of Jquery Addon

Permalink
I am trying to get my addon, Social Feed, to pass all the automatic tests when uploading a new version. However, 2 of the tests fail:
1. Exec or die statements not used
2. Uses json_decode functions

The plugin is a jquery plugin that calls two PHP scripts, which are needed for the plugin to work. Both PHP scripts do not interact with Concrete5 directly in any way.

When I try adding the "exec or die" statements to the script, the plugin does not display / work properly.

What is the proper way to address and fix both the above issues?

This is for Concrete 5.6.

PineCreativeLabs
 
Justin1978 replied on at Permalink Reply
Justin1978
I have an add-on under review at the moment and it uses 3rd party libraries which don't have the exec or die statements either. They can be excempted by the reviewers under specific conditions. You will have to motivate that on the review page of your add-on.

json_decode and system i/o functions pose security issues, I think That's why they are not allowed. Getting exempted for that is propably a bigger issue. Browse Concrete's libraries (in the vendor folder) and Concrete's utility classes to see if they have a json parser. Then you can use those. I did the same with file_put_contents, mk_dir and require by using \Illuminate\Filesystem\Filesystem which is in the vendor folder.
ramonleenders replied on at Permalink Reply
ramonleenders
The OP said it's about 5.6, and there's no vendor (composer) there. You will have to look through the helper files I guess, if it's there. But most likely the peer reviewers can help you on that as well. Just post a comment, so they know it's failing. Sometimes when one or mulitple tests failed, they don't look at your submission (or it doesn't get flagged to review or something, not sure).

As for exec or die, if you can motivate why it shouldn't be there and it doesn't work without it, shouldn't be an issue.