MyBlog is a secure blogging platform built using Java EE, JSP, and Servlets, following the Zero Trust Security Model to ensure safe user interactions and data protection.
- ✅ Zero Trust Architecture (JWT Authentication, Role-Based Access Control)
- ✅ Strong Password Policies (8+ characters, special characters, and numbers)
- ✅ Session Expiry & Token-Based Access
- ✅ CSRF & CORS Protection
- 🔐 OAuth Integration (Google Sign-In)
- 🖊️ Create, edit, and delete blog posts
- 📌 Like, comment, and share blogs
- 🔖 Save favorite blogs for later
- 👥 Manage users and their access levels
- 📚 Categorize and organize blogs
- 🗑️ Moderate and delete inappropriate content
- 🧾 Blockchain-based Donation Logging using Solidity smart contracts
- 🪙 Donations stored securely on an Ethereum-compatible testnet
- 🔗 Integrated with Web3j and Ganache for contract deployment and interaction
- Backend: Java EE (Servlets, JSP), MySQL, JDBC
- Frontend: HTML, CSS (Bootstrap), JavaScript
- Security: JWT Authentication, BCrypt Hashing, OAuth 2.0
- Blockchain: Solidity, Web3j, Ganache
- APIs: ipapi (IP Geolocation API)
- Tools: Tomcat, Eclipse/IntelliJ, GitHub
-
Clone the repository
git clone https://github.com/your-username/myblog.git cd myblog -
Import into Eclipse/IntelliJ (as a Maven/Java EE project)
-
Set up the database
- Import the provided SQL file into MySQL
- Update
db.propertieswith your database credentials
-
Configure Blockchain Environment
- Install Ganache
- Start a local blockchain workspace
- Compile and deploy the Solidity smart contract
- Update Web3j configuration and contract address in your Java project
-
Enable Google OAuth
- Create a project on Google Cloud Console
- Set OAuth 2.0 Client ID & redirect URI
- Add credentials to
oauth.propertiesor the servlet
-
Set up IP Geolocation (ipapi)
- Register at ipapi.com
- Add your API key to your servlet or helper class
- Use it to track and log IP geolocation on login
-
Run the project on Tomcat
- MyBlogAPI service is a backed that searve the website blogs
- SmartContract the SmartContract used for Tiping ather withe eth
This project is open-source under the MIT License.




