Used Traccar Server / Client for my Undergrad Capstone Project - Thank you Traccar!

Jacob Yuhas7 years ago

Just wanted to share here a great success my capstone group had with Traccar. For our capstone project we were required to make a website and a prototype of some product of our own. We decided to make a "Wallet Tracker." The whole idea was more marketing than anything but it was an IT capstone course so we decided to include something within the scope of technology beyond what was taught at the school. We also had to include one thing we learned in the curriculum which we chose Python (along with multiple other things we picked up). Our group won the competition for the best product and our grade was already posted as an A for the course.

IT Capstone Course: Pretty much wraps up the the IT curriculum. You take everything that you have learned and apply it to a real-life scenario. This class was to market a website. The Professor asked us to not worry about too much of coding, he just wanted to see where our imagination took us. Google Sites was acceptable due to the fact that he wanted us to think our projects through with what we have learned. Promote backend thought with a pretty front-end.

We decided it would be cheating just to throw up a Traccar Server everyone logs into. We wanted to show our logo and enforce security of not having a live map being streamed across the internet. So we setup a django webserver that scrapes the Traccar log file for the device ID and it's last known location. Then, upon a get request of the page where we show a Google Map, it updates an embedded Google map that is "secure to the user." (We had to grab a Google API key for that as well, which wasn't hard and free up to 2500 requests a month).

Due to time constraints we were not able to hash/salt the databases and enforce HTTPS. SSL certificates from GoDaddy were $40 dollars. We were also only able to have time to get this to work for one device. Again, the main focus was the marketing the website itself. (This capstone course is shared with Management Information Systems majors and Information Technology majors so it makes sense).

Due to budget constraints we weren't able to make our own device, but we chose something as close to it as possible, which was a phone (Samsung Galaxy S6 with the Traccar client on it). So there may have been fluff but the professor asked for a prototype, not a full product.

Github Repo: https://github.com/sneakdella/WalletTrakker
The Scrape File itself: https://github.com/sneakdella/WalletTrakker/blob/master/WalletTrakker/app/scrape.py
Super User/Pass: f+Ndm-t0d4y / In$troM3nT (if it gives you issues just make a new super-user).

Final Presentation: https://docs.google.com/presentation/d/1Iy7QhIZ0_smLoocz5QSKtantUq1ctT66nHTcjAnKW_4/edit?usp=sharing
Google Sites Prototype: https://sites.google.com/view/wallettrakker/home

Final Presentation includes pretty much everything we planned out, including the timeline.

If you want to check it out, you will have to change the variable of "log_file" in scrape.py to the absolute path of the Traccar log file. Also, if you get a "list_index out of range" runtime error when starting the Django server, make sure the Traccar server is running and already logging a device's location. Also, don't forget to install the extra packages from "requirements.txt".

Thank you Traccar community for allowing me to end college with a bang.

Jacob Yuhas7 years ago

Edit: We did reveal that we used an open source GPS server. One of the judges asked and we showed them that we made use of an open source software to save time. (We showed them Traccar) After explaining SSL and hashing database entries was our plan to deter man in the middle attacks or a device compromise, they didn't question the security of it; more the legality of using Traccar or other open source software for commercial use.

My group has also decided to not move forward with the project though. While it's a great idea, our Professor asked, but the R&D of designing hardware for this would be extremely expensive and outside of our trade.

Anton Tananaev7 years ago

Good job. Some comments:

  • You can get free SSL certificates from Let's Encrypt. That's what pretty much everyone does nowadays.
  • Instead of scraping log file, I would recommend using Traccar API. It's the right way.
  • Encrypting data in the database is not a common practice, except for passwords. Also, SHA-256 is a one-way encryption, so even you won't be able to retrieve your data.
  • There are no limitation to use Traccar for commercial purposes.

I know that you won't continue this project, so these comments mostly addressed to others who read this thread.

Jacob Yuhas7 years ago

To be honest it was a bit of a rush in the end when we decided to do a live demo. We had two weeks to get it rolling.

We attempted API but the other group members weren't understanding Django enough so we simplified it by focusing on Django basics (unrelated to the project) and then scraping the log file instead. Which for the majority of our program, it made sense. A lot of our scripting assignments were targeted at log files and using regular expressions to display the information needed.

We also didnt have time to focus on the SSL itself because we werent that familiar with nginx or apache2. Those were left for the Computer Science students.

I appreciate the input though, I really did want to use the API but we wanted to remember what we learned as there was a lot to learn. Just not enough time unfortunately.