Password protection (Rally Antilag anytime soon?)

Testing and development of Megasquirt 3

Moderators: jsmcortina, muythaibxr

opel
Helpful MS/Extra'er
Posts: 88
Joined: Wed Jun 18, 2008 10:33 pm

Re: Password protection (Rally Antilag anytime soon?)

Post by opel »

Just de-solder the serial and usb ports... problem solved.
kjones6039
Super MS/Extra'er
Posts: 1986
Joined: Sat Jul 22, 2006 8:02 pm
Location: Eureka, NV USA
Contact:

Re: Password protection (Rally Antilag anytime soon?)

Post by kjones6039 »

I'm thinking...... Retinal recognition?
1979 Corvette - 383 CID SBC w/ Holley Pro-Jection 900 CFM TBI, 4-85 lb lo-z injectors & Walbro 255 pump
MS2 v3 w/extra 3.4.2 Release
36-1, Delphi LS2/7 coils in wasted spark, driven by v2.0 logic board from JBPerformance
Spartan Lambda Sensor from 14point7
TinyIOX from JBPerformance
piledriver
Super MS/Extra'er
Posts: 1681
Joined: Tue Oct 27, 2009 6:24 am
Location: Van Alstyne, Texas

Re: Password protection (Rally Antilag anytime soon?)

Post by piledriver »

kjones6039 wrote:I'm thinking...... Retinal recognition?
IIRC that has been long ago defeated, along with Blu-ray.
Note the movie studios et al spent years//MILLIONS developing the DRM for blu-ray.
(but it still was only a speedbump to professional pirates, still a PITA for ~everyone else)

Looks like the simplest thing that might be secure (but not to anyone with a screwdriver or soldering gun)
BT adapter mounted internally with a good long PIN, no pins routed out.
Always doing things the hard way, MS2 sequential w/ v1.01 mainboard, LS2 coils. 80 mile/day commuter status.
Reverant
Super MS/Extra'er
Posts: 1233
Joined: Sat Apr 15, 2006 12:39 am
Location: Athens, Greece

Re: Password protection (Rally Antilag anytime soon?)

Post by Reverant »

Desoldering serial/usb ports is plain silly. People are smart enough to resolder a single connector.

DRM systems can't be compared to an ECU.

Btw, most microcontrollers have the abiliity to lock down the firmware for further viewing or altering. To my knowledge, on most uCs, there's no way to bypass that system once locked down (in fact, the MS3 bootloader is locked down for fears of piracy/counterfeiting).

A system to prevent tampering (or different levels of access given a password) can be implemented, quite efficiently in fact.

No password = no lock
Password A set = read only. If you can provide the proper password, you can read the tune, but not overwrite the tune, nor flash a new firmware in place.
Password B set = write only. If you can provide the proper password, you can flash a new a tune, or flash a new firmware. You can't read the current tune.
Password C set = datalog only. If you can provide the proper password, you can datalog but can't do anything else. Which parameters can be datalogged can be selected. Alternatively, have a 2-level datalog (minimal datalog [RPM/MAP/TPS/CLT/IAT/BAT/Inj Duty?], full datalog) based on 2 different passwords.
Any combination of the above is also possible.

The problem is that at the current level of development, a lot has to change for this to implemented. The MS3 developers are already short of time.

The question is, if someone else were to develop this feature, would the developers integrate the code given?
The man behind MS Labs
2005 Audi A3 2.0L TFSI DSG AWD - Extreme MS3
2002 Mazda Miata 1.8 6sp - Enhanced MS3 1.4.0, sequential injection, sequential ignition, big turbo, lots of boost
racingmini_mtl
Super MS/Extra'er
Posts: 9130
Joined: Sun May 02, 2004 6:51 am
Location: Quebec, Canada
Contact:

Re: Password protection (Rally Antilag anytime soon?)

Post by racingmini_mtl »

It has been mentioned more than once (much more in fact) that you can't do that without changing the bootloader. That means that it cannot be retrofitted by the user and would require returning the existing MS3s for reflashing. Also since no one has the source code for the bootloader except the developers and any such scheme would require a very tight integration with the bootloader code, it can't be done independently by someone else.

I should mention that I don't have access to the MS3 bootloader source code or know the details of how it works so I am making some educated assumptions for my claims above. But James has already confirmed most of it anyway.

Jean
jbperf.com Main site . . . . . . . . . . . . . . . . . . . . . . jbperf.com Forum
Image
Reverant
Super MS/Extra'er
Posts: 1233
Joined: Sat Apr 15, 2006 12:39 am
Location: Athens, Greece

Re: Password protection (Rally Antilag anytime soon?)

Post by Reverant »

The bootloader modification is indeed something that has to be done by someone that has the source for it. Obviously no way around that.
The man behind MS Labs
2005 Audi A3 2.0L TFSI DSG AWD - Extreme MS3
2002 Mazda Miata 1.8 6sp - Enhanced MS3 1.4.0, sequential injection, sequential ignition, big turbo, lots of boost
jsmcortina
Site Admin
Posts: 39617
Joined: Mon May 03, 2004 1:34 am
Location: Birmingham, UK
Contact:

Re: Password protection (Rally Antilag anytime soon?)

Post by jsmcortina »

The monitor fully occupies the region allocated for it. I've not looked in detail, but to extend this would require fairly far reaching changes to memory allocation.

James
I can repair or upgrade Megasquirts in UK. http://www.jamesmurrayengineering.co.uk

My Success story: http://www.msextra.com/forums/viewtopic ... 04&t=34277
MSEXTRA documentation at: http://www.msextra.com/doc/index.html
New users, please read the "Forum Help Page".
gslender
Super MS/Extra'er
Posts: 1072
Joined: Fri Sep 16, 2011 5:29 am
Location: Brisbane, Australia
Contact:

Re: Password protection (Rally Antilag anytime soon?)

Post by gslender »

Reviving and old thread....

Another reason for simple password lock out for tune updates is some countries have a regulatory requirement that any ECU used for street use, that passes the emission controls (assuming it did) would also need to have a non-modifiable ECU/tune... so adding a password meets that requirement!

At least the competitive brand ECUs are being used for that very reason, and getting passed by local authorities who are too clueless to realize that 15 mins after being passed, they passwords are being wiped and the car is being driven with an open tune/config (but the owner has the certificate for having the engine emission passed etc).

Even a simple TunerStudio / ECU firmware option that refuses to play unless the password is correct would be a step in that direction (though old versions of TS would simply ignore that pwd field) - a further improvement could be an upgrade to the tune serial output that uses something simple like Rot13 to confuse old version of TS and that only the latest TS with the correct pwd would allow the tune to updated.

I know it could be bypassed, and it isn't DRM secure, but the point is to add that competitive simple feature that other ECUs have that people are buying so that they can get around a legislated rule for street driven tunes.

G
Mazda MX5 + MS3 Pro
jsmcortina
Site Admin
Posts: 39617
Joined: Mon May 03, 2004 1:34 am
Location: Birmingham, UK
Contact:

Re: Password protection (Rally Antilag anytime soon?)

Post by jsmcortina »

Without a total re-engineering, any password scheme would be very easy to bypass. It could perhaps be useful to prevent accidental changes to the tune.

James
I can repair or upgrade Megasquirts in UK. http://www.jamesmurrayengineering.co.uk

My Success story: http://www.msextra.com/forums/viewtopic ... 04&t=34277
MSEXTRA documentation at: http://www.msextra.com/doc/index.html
New users, please read the "Forum Help Page".
piledriver
Super MS/Extra'er
Posts: 1681
Joined: Tue Oct 27, 2009 6:24 am
Location: Van Alstyne, Texas

Re: Password protection (Rally Antilag anytime soon?)

Post by piledriver »

jsmcortina wrote:Without a total re-engineering, any password scheme would be very easy to bypass. It could perhaps be useful to prevent accidental changes to the tune.

James
For that reason alone it may prove useful, even if it was just some (selectable) shennanigans with TunerStudio comms to inhibit writes.
Of course BT comms have a PIN that is technically DRM, would that count? (not that I'd suggest tuning via BT, still very iffy IME)

It would finally kill this thread :twisted:

Idea: Implement a checksum function for msq in tunerstudio, and have a check field for that.
Would that be enough to satisfy the legal drones, if there was a checksum validation to the "tested" tune?

(That way you could have an emissions legal tune like all the modern Ford/GM guys, and just reload as needed.
Some ACVW people have complete motors they swap in annually for a day for California emissions checks...)
Always doing things the hard way, MS2 sequential w/ v1.01 mainboard, LS2 coils. 80 mile/day commuter status.
gslender
Super MS/Extra'er
Posts: 1072
Joined: Fri Sep 16, 2011 5:29 am
Location: Brisbane, Australia
Contact:

Re: Password protection (Rally Antilag anytime soon?)

Post by gslender »

It must be locked - but locked isn't defined. So I guess physically locking the ECU in a case would qualify.

Whatever your view, competitive ECUs have this feature and I'm surprised that alone isn't good enough reasons to ensure customers don't shop elsewhere
Mazda MX5 + MS3 Pro
piledriver
Super MS/Extra'er
Posts: 1681
Joined: Tue Oct 27, 2009 6:24 am
Location: Van Alstyne, Texas

Re: Password protection (Rally Antilag anytime soon?)

Post by piledriver »

gslender wrote:It must be locked - but locked isn't defined. So I guess physically locking the ECU in a case would qualify.

Whatever your view, competitive ECUs have this feature and I'm surprised that alone isn't good enough reasons to ensure customers don't shop elsewhere

A firmware checksum is all most of the factory ECUs could have (?), given the plethora of "tuning hardware" available.
A lot of "Tuners" won't switch anyway, they have one tool they know how to use and are not interested in learning anything else.

DTAFast seems to lack password protection? I thought that was just rebranded AiM like ~half the ECU brands out there.
I'm curious What "competitive ECUs" actually support it?
Always doing things the hard way, MS2 sequential w/ v1.01 mainboard, LS2 coils. 80 mile/day commuter status.
JoseMiguel
Master MS/Extra'er
Posts: 652
Joined: Thu Dec 09, 2010 3:48 pm

Re: Password protection (Rally Antilag anytime soon?)

Post by JoseMiguel »

I second to gs arguments... Password protection is everywhere else :(
gslender
Super MS/Extra'er
Posts: 1072
Joined: Fri Sep 16, 2011 5:29 am
Location: Brisbane, Australia
Contact:

Re: Password protection (Rally Antilag anytime soon?)

Post by gslender »

piledriver wrote:I'm curious What "competitive ECUs" actually support it?
AEM, Haltech and Motec all offer this.

In Australia, these ECUs are way, way more popular than Megasquirt.

So whilst the MS3Pro is now a viable a competitive option, it will need to offer similar features to sell.

I'm not sure if anyone cares about sales, but if they do, then they need to think about what features will stop or detract from sales.

G
Mazda MX5 + MS3 Pro
piledriver
Super MS/Extra'er
Posts: 1681
Joined: Tue Oct 27, 2009 6:24 am
Location: Van Alstyne, Texas

Re: Password protection (Rally Antilag anytime soon?)

Post by piledriver »

So on those ECUs, does the password "protection" somehow "protect" the person who owns the ECU and paid for the tune, or force the ECUs owner to come back to the tuner for any changes?

IMHO if someone pays for a tune, they own it, not the tuner.
Works the same way with Musicians, programmers, "work for hire" etc.
If tuners want to be some legally "special" class they may be disappointed.
(perhaps my US based viewpoint is biased vs the rest of the world)

If it is simply a method to extort customers and enforce going back to that same tuner, that sucks and is likely illegal in many locales...
Of course I could see some tuners would absolutely adore it.
Perhaps B&G and the suppotting coders here don't want to support that sort of lock down.

Ethically I hope the powers that be will never implement that sort of extortion-freindly password "protection".
Last edited by piledriver on Sun Aug 17, 2014 11:30 pm, edited 1 time in total.
Always doing things the hard way, MS2 sequential w/ v1.01 mainboard, LS2 coils. 80 mile/day commuter status.
gslender
Super MS/Extra'er
Posts: 1072
Joined: Fri Sep 16, 2011 5:29 am
Location: Brisbane, Australia
Contact:

Re: Password protection (Rally Antilag anytime soon?)

Post by gslender »

piledriver wrote:So on those ECUs, does the password "protection" somehow "protect" the person who owns the ECU and paid for the tune, or force the ECUs owner to come back to the tuner for any changes?

IMHO if someone pays for a tune, they own it, not the tuner.
Works the same way with Musicians, programmers, "work for hire" etc.
If tuners want to be some legally "special" class they may be disappointed.

If it is simply a method to extort customers and enforce going back to that same tuner, that sucks and is likely illegal in many locales...
Of course I could see some tuners would absolutely adore it.
Who cares !? That's a philosophical argument that you can take up with your tuner.

Another way of looking at it is that technically, if you pay someone to install and tune the ECU, why would you want to modify the tune anyway? And if so, do you expect to be able to go back and complain if it doesn't idle in the cold (some 5 months later) ??? A lock or some way of ensuring no tamper has occurred is a good way to solve installer warranty. Some installers won't even consider an ECU that doesn't offer some way to protect them from customer who fiddle and screw up a good tune.

End of the day, it is a password on the tune. If you get/know the password then you can use it to change/update and even remove the password on the tune. If you don't, then unless you are really, really smart (like some folks on this forum who could reverse engineer a ROT13 encoded tune to derive the password) then you can't open/edit the tune and you'll have to start again.

G
Mazda MX5 + MS3 Pro
piledriver
Super MS/Extra'er
Posts: 1681
Joined: Tue Oct 27, 2009 6:24 am
Location: Van Alstyne, Texas

Re: Password protection (Rally Antilag anytime soon?)

Post by piledriver »

gslender wrote:
piledriver wrote:So on those ECUs, does the password "protection" somehow "protect" the person who owns the ECU and paid for the tune, or force the ECUs owner to come back to the tuner for any changes?

IMHO if someone pays for a tune, they own it, not the tuner.
Works the same way with Musicians, programmers, "work for hire" etc.
If tuners want to be some legally "special" class they may be disappointed.

If it is simply a method to extort customers and enforce going back to that same tuner, that sucks and is likely illegal in many locales...
Of course I could see some tuners would absolutely adore it.
Who cares !? That's a philosophical argument that you can take up with your tuner.

Another way of looking at it is that technically, if you pay someone to install and tune the ECU, why would you want to modify the tune anyway? And if so, do you expect to be able to go back and complain if it doesn't idle in the cold (some 5 months later) ??? A lock or some way of ensuring no tamper has occurred is a good way to solve installer warranty. Some installers won't even consider an ECU that doesn't offer some way to protect them from customer who fiddle and screw up a good tune.

End of the day, it is a password on the tune. If you get/know the password then you can use it to change/update and even remove the password on the tune. If you don't, then unless you are really, really smart (like some folks on this forum who could reverse engineer a ROT13 encoded tune to derive the password) then you can't open/edit the tune and you'll have to start again.

G
There are likely folks on this forum who could decrypt a PGP 256 bit encrypted file in a few days of computer time if it was worth the effort, particularly as parts of the files content//format etc are known..

A simple MD5 (or better) hash of the tune and loaded firmware for validation purposes would achieve all the confirmation a tuner needs for protection from "warranty" claims and likely many other legal validation purposes. If it was built into TS it would be a great feature.
Always doing things the hard way, MS2 sequential w/ v1.01 mainboard, LS2 coils. 80 mile/day commuter status.
gslender
Super MS/Extra'er
Posts: 1072
Joined: Fri Sep 16, 2011 5:29 am
Location: Brisbane, Australia
Contact:

Re: Password protection (Rally Antilag anytime soon?)

Post by gslender »

piledriver wrote:A simple MD5 hash of the tune and loaded firmware for validation purposes would achieve all the confirmation a tuner needs for protection from "warranty" claims and likely many other legal validation purposes. If it was built into TS it would be a great feature.
I agree for many reasons that would be ideal. To make it simple, something like the bcrypt algo is well tested and used and available in licenses that should allow both TS and the ECU firmware to use.
http://en.wikipedia.org/wiki/Bcrypt

G
Mazda MX5 + MS3 Pro
gslender
Super MS/Extra'er
Posts: 1072
Joined: Fri Sep 16, 2011 5:29 am
Location: Brisbane, Australia
Contact:

Re: Password protection (Rally Antilag anytime soon?)

Post by gslender »

Oh, and it would improve the tune/project connection time - instead of reading the entire tune to confirm that it has/hasn't changed, it could just ask the ECU for the hash, and compare to the local hash of the tune and if the same, just connect. If not, it would only then pull down the 8 pages of memory etc.... much more efficient and intelligent that what is done now. An improvement from that could be to hash each page and only pull the page that is different/inconsistent etc.

G
Mazda MX5 + MS3 Pro
piledriver
Super MS/Extra'er
Posts: 1681
Joined: Tue Oct 27, 2009 6:24 am
Location: Van Alstyne, Texas

Re: Password protection (Rally Antilag anytime soon?)

Post by piledriver »

Excellent idea!
Could cut down on flash writes as well, or is it an all or nothing sort of event?
Always doing things the hard way, MS2 sequential w/ v1.01 mainboard, LS2 coils. 80 mile/day commuter status.
Post Reply