Class Guard: Securing Educational Data with Fine-Grained Authorization Using Permit.io

This is a submission for the Permit.io Authorization Challenge: Permissions Redefined What I Built I built a web application called "Class Guard" that allows educational facilitators to manage tasks and projects assigned to teachers and students. The application supports multiple user roles, including admin, teacher, and student, each with distinct levels of access and permissions. The core problem this application solves is the need for fine-grained authorization to ensure that users can only access and modify the data they are authorized to handle. Demo Project Repo Vist the Class Guard on Github My Journey Having seen this challenge just on May 2nd, I was initially very distressed and considered abandoning it. However, I was inspired when I discovered that a fellow African had just won the WeCoded challenge. This motivated me to embark on the project. Initially, the application was called "Class Lock," but I later changed it to "Class Guard." The idea for Class Guard was derived from my high school days during the COVID-19 era. The school I attended developed a software for online tutoring. During a quiz, I accidentally input the "&" symbol into an input field, and it revealed the answer. I was perplexed and tried it on another input page, which also showed the exact reply. Amazed, I shared this discovery with a few friends, who in turn shared it with others. After two weeks, the issue was fixed, and the public report stated that the developer had inadvertently included a parameter with "&admin" for some unknown reason. As a result, we had to take additional tests to make up for the ones we had cheated on. Now, as a student studying computer engineering, I came up with Class Guard to assist teachers, students, and admins (proprietors) in ensuring that the right data ends up with the authorized personnel. Despite starting the project late, I had to push my brain to work at maximum capacity. As a solo developer working on a mini Chromebook with a mere 2GB of RAM, my system was often lagging at 100% CPU usage, but I persevered. I developed the front-end using React and the authorization system using the secure Permit.io CLI, while the back-end was built with Node.js. The main challenges I faced were the lack of time to thoroughly read the Permit.io documentation and the limited understanding provided by AI. However, I used my prompt engineering skills effectively and achieved good results. The second phase of the challenge came when I deployed the application on Netlify, but I managed to overcome this as well and ultimately succeeded. Using Permit.io for Authorization First i had to get admitted and create a account on Permit.io. It has very good UI but very complex.. like i cant figure out what the #instance(admin) work.. but i finally figured how to use it and add a resource :) Why i prefer Permit.io to Traditional methods Traditional Authorization Systems: Complexity: Traditional systems often require extensive coding and configuration to manage user roles and permissions. Maintenance: They can be difficult to maintain and update, especially as the application grows. Security: They are more prone to security vulnerabilities due to manual configuration and human error. _ Scalability_: Scaling traditional systems can be challenging and resource-intensive. Permit.io Advances: Simplicity : Permit.io simplifies the process of setting up and managing fine-grained authorization with its intuitive CLI and robust API. Ease of Maintenance : The platform provides tools and documentation that make it easier to manage and update permissions, reducing the risk of errors. Enhanced Security : Permit.io’s built-in security features and best practices help prevent common vulnerabilities, ensuring that your application remains secure. Scalability : It is designed to scale seamlessly, making it easier to handle growing user bases and complex permission structures. Advantages of Using Permit.io Time-Saving: The secure Permit.io CLI and API save developers a significant amount of time by automating many of the tedious tasks associated with authorization. Reliability: With Permit.io, you can trust that your authorization logic is handled correctly, reducing the likelihood of bugs and security issues. Flexibility: The platform supports a wide range of use cases and can be easily integrated into existing applications, making it a versatile solution. Community and Support: Permit.io has a growing community and robust support resources, which can be invaluable when facing challenges or seeking best practices. Acknowledgement All thanks to Mr Or Weis and Mr Asaf Cohen(Creators of Permit.io) for this wonderful challenge.

May 4, 2025 - 22:13
 0
Class Guard: Securing Educational Data with Fine-Grained Authorization Using Permit.io

This is a submission for the Permit.io Authorization Challenge: Permissions Redefined

What I Built

I built a web application called "Class Guard" that allows educational facilitators to manage tasks and projects assigned to teachers and students. The application supports multiple user roles, including admin, teacher, and student, each with distinct levels of access and permissions. The core problem this application solves is the need for fine-grained authorization to ensure that users can only access and modify the data they are authorized to handle.

Demo

Image description

Project Repo

Vist the Class Guard on Github

My Journey

Having seen this challenge just on May 2nd, I was initially very distressed and considered abandoning it. However, I was inspired when I discovered that a fellow African had just won the WeCoded challenge. This motivated me to embark on the project. Initially, the application was called "Class Lock," but I later changed it to "Class Guard."

The idea for Class Guard was derived from my high school days during the COVID-19 era. The school I attended developed a software for online tutoring. During a quiz, I accidentally input the "&" symbol into an input field, and it revealed the answer. I was perplexed and tried it on another input page, which also showed the exact reply. Amazed, I shared this discovery with a few friends, who in turn shared it with others. After two weeks, the issue was fixed, and the public report stated that the developer had inadvertently included a parameter with "&admin" for some unknown reason. As a result, we had to take additional tests to make up for the ones we had cheated on.

Now, as a student studying computer engineering, I came up with Class Guard to assist teachers, students, and admins (proprietors) in ensuring that the right data ends up with the authorized personnel. Despite starting the project late, I had to push my brain to work at maximum capacity. As a solo developer working on a mini Chromebook with a mere 2GB of RAM, my system was often lagging at 100% CPU usage, but I persevered.

I developed the front-end using React and the authorization system using the secure Permit.io CLI, while the back-end was built with Node.js. The main challenges I faced were the lack of time to thoroughly read the Permit.io documentation and the limited understanding provided by AI. However, I used my prompt engineering skills effectively and achieved good results. The second phase of the challenge came when I deployed the application on Netlify, but I managed to overcome this as well and ultimately succeeded.

Image description

Image description

Using Permit.io for Authorization

First i had to get admitted and create a account on Permit.io. It has very good UI but very complex.. like i cant figure out what the #instance(admin) work.. but i finally figured how to use it and add a resource :)

Image description

Why i prefer Permit.io to Traditional methods

Traditional Authorization Systems:
Complexity: Traditional systems often require extensive coding and configuration to manage user roles and permissions.
Maintenance: They can be difficult to maintain and update, especially as the application grows.
Security: They are more prone to security vulnerabilities due to manual configuration and human error.
_ Scalability_: Scaling traditional systems can be challenging and resource-intensive.

Permit.io Advances:
Simplicity : Permit.io simplifies the process of setting up and managing fine-grained authorization with its intuitive CLI and robust API.
Ease of Maintenance : The platform provides tools and documentation that make it easier to manage and update permissions, reducing the risk of errors.
Enhanced Security : Permit.io’s built-in security features and best practices help prevent common vulnerabilities, ensuring that your application remains secure.
Scalability : It is designed to scale seamlessly, making it easier to handle growing user bases and complex permission structures.

Advantages of Using Permit.io
Time-Saving: The secure Permit.io CLI and API save developers a significant amount of time by automating many of the tedious tasks associated with authorization.
Reliability: With Permit.io, you can trust that your authorization logic is handled correctly, reducing the likelihood of bugs and security issues.
Flexibility: The platform supports a wide range of use cases and can be easily integrated into existing applications, making it a versatile solution.
Community and Support: Permit.io has a growing community and robust support resources, which can be invaluable when facing challenges or seeking best practices.

Acknowledgement

All thanks to Mr Or Weis and Mr Asaf Cohen(Creators of Permit.io) for this wonderful challenge.