ranchito Posted June 28, 2016 Report Share Posted June 28, 2016 Hi. I created a flag and want to add a license. use the machine id They know some tutorial on how to do this? thanks Quote Link to comment Share on other sites More sharing options...
⭐ JDizzle22 Posted June 28, 2016 Report Share Posted June 28, 2016 Hi. I created a flag and want to add a license. use the machine id They know some tutorial on how to do this? thanks It really depends on what you are trying to do. If you are trying to do some sort of server validation, that is going to be a lot more involved, but here is something to get you started if it is hard coding machine ID's private bool ValidMachine = false; protected override void OnStartUp() { ValidMachine = false; if (NinjaTrader.Cbi.License.MachineID == "MACHINEIDGOESHERE") ValidMachine = true; } Here's another idea on hard coding a list of valid machine IDs: http://m.ninjatrader.com/support/forum/showthread.php?p=277780 Quote Link to comment Share on other sites More sharing options...
lbf4223 Posted June 28, 2016 Report Share Posted June 28, 2016 If I had created a unique indicator which had a trading edge, I wouldn't license it. I'd use it to become fabulously wealthy from my own ingenuity. Quote Link to comment Share on other sites More sharing options...
admis Posted June 28, 2016 Report Share Posted June 28, 2016 Of course, such kind of protections are valid, but keep in mind, that can be broken in the time below 1 min... Quote Link to comment Share on other sites More sharing options...
imfm Posted June 28, 2016 Report Share Posted June 28, 2016 the only HARD method to Protect actually .net code is move all Licensgin and validation to X86 dll externally the problme is EXPENSIVE you need hire a coder that build it for you Quote Link to comment Share on other sites More sharing options...
ranchito Posted June 28, 2016 Author Report Share Posted June 28, 2016 Yes thanks . It is easy to break, but I want to learn anyway. I was testing and I could not make it. Quote Link to comment Share on other sites More sharing options...
ranchito Posted June 29, 2016 Author Report Share Posted June 29, 2016 It really depends on what you are trying to do. If you are trying to do some sort of server validation, that is going to be a lot more involved, but here is something to get you started if it is hard coding machine ID's private bool ValidMachine = false; protected override void OnStartUp() { ValidMachine = false; if (NinjaTrader.Cbi.License.MachineID == "MACHINEIDGOESHERE") ValidMachine = true; } Here's another idea on hard coding a list of valid machine IDs: http://m.ninjatrader.com/support/forum/showthread.php?p=277780 simply put this code in the indicator? because I have tried and I could not achieve it. Thank you Quote Link to comment Share on other sites More sharing options...
⭐ JDizzle22 Posted June 29, 2016 Report Share Posted June 29, 2016 Take a look at this example: https://www.sendspace.com/file/cppt2v Like everyone else said, this would be extremely easy to bypass/break, but at least it's a start to learning. Quote Link to comment Share on other sites More sharing options...
ranchito Posted June 29, 2016 Author Report Share Posted June 29, 2016 Take a look at this example: https://www.sendspace.com/file/cppt2v Like everyone else said, this would be extremely easy to bypass/break, but at least it's a start to learning. thank you very much, no matter it easy. should paste this code into the formula of any indicator? From already thank you very much Quote Link to comment Share on other sites More sharing options...
⭐ JDizzle22 Posted June 29, 2016 Report Share Posted June 29, 2016 thank you very much, no matter it easy. should paste this code into the formula of any indicator? From already thank you very much You should be able to use that code in any of the indicators you have developed. Again, extremely easy to bypass, so it will be virtually useless if you are distributing your indicator to anyone other than yourself. admis 1 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.