Skip to content

MohosinMiah/Blog-Application-using-Spring-Boot

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

59 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Blog-Application-using-Spring-Boot

Blog Application using Spring Boot Feature : Full Blog functionality with Spring Role Permission Based Security Using JWT

How to run this project

  1. First clone the project
clone https://github.com/MohosinMiah/Blog-Application-using-Spring-Boot.git
  1. Then run project http://localhost:8080

API Resource and Documentation

Postman API Resource

https://github.com/MohosinMiah/Blog-Application-using-Spring-Boot/blob/main/necessary_resource/Blog%20Application.postman_collection.json

API Documentation

https://documenter.getpostman.com/view/4954358/2s946k7qun

Database

https://github.com/MohosinMiah/Blog-Application-using-Spring-Boot/blob/main/necessary_resource/blogapplication.sql

Project Feature

Project Name: Blog application with Role-Based Security

This project aims to provide a fully functional blog application with features like creating and managing posts, commenting on posts, and organizing posts by categories. The application is secured using Spring Security with Role-Based Access Control (RBAC) and employs JSON Web Tokens (JWT) for authentication.

Features

  1. User Registration and Login: Users can register an account and log in to the application using their credentials.

  2. Role-Based Security: The application uses Role-Based Access Control (RBAC) to define different levels of access for users. The roles typically include ROLE_USER, ROLE_ADMIN, etc.

  3. JSON Web Tokens (JWT) Authentication: JWT is used for authentication, ensuring secure communication between the client and server.

  4. Create and Manage Blog Posts: Authenticated users can create, edit, and delete their blog posts.

  5. Comments on Posts: Users can add comments to blog posts to engage in discussions.

  6. Categorize Posts: Blog posts can be organized into different categories for easy navigation and filtering.

Tech Stack

  • Spring Boot
  • Spring Security
  • Spring Data JPA
  • MySQL (or any other database of your choice)
  • JSON Web Tokens (JWT) for authentication

Installation

  1. Clone the repository:
git clone https://github.com/your-username/spring-blog.git
  1. Configure the database connection in application.properties:
spring.jpa.hibernate.ddl-auto=update
spring.datasource.url=jdbc:mysql://localhost:3306/blogapplication
spring.datasource.username=root
spring.datasource.password=
spring.datasource.driver-class-name=com.mysql.cj.jdbc.Driver
spring.jpa.show-sql: true
  1. Run the application:
mvn spring-boot:run

The application will be accessible at http://localhost:8080.

Usage

  1. Visit the application in your browser.

  2. Register a new account or log in if you already have one.

  3. Explore the blog posts, create new posts, and add comments.

  4. Admin users (with appropriate roles) will have additional privileges, such as managing users and categories.

Thank you Happy coding :)

About

Blog Application using Spring Boot

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages