All Projects → Pyknic → speedment-secure-rest-example

Pyknic / speedment-secure-rest-example

Licence: Apache-2.0 License
An example project showcasing how to build a secure REST API with Speedment and Spring Boot.

Programming Languages

java
68154 projects - #9 most used programming language

Projects that are alternatives of or similar to speedment-secure-rest-example

kemal-basic-auth
Basic auth for your Kemal application
Stars: ✭ 14 (-17.65%)
Mutual labels:  basic-authentication
serverless-static-hosting-with-basic-auth
Serverless boilerplate for Static website hosting with Basic authentication
Stars: ✭ 21 (+23.53%)
Mutual labels:  basic-authentication
s3-proxy
S3 Reverse Proxy with GET, PUT and DELETE methods and authentication (OpenID Connect and Basic Auth)
Stars: ✭ 106 (+523.53%)
Mutual labels:  basic-authentication
horse-basic-auth
Middleware for Basic Authentication in HORSE
Stars: ✭ 37 (+117.65%)
Mutual labels:  basic-authentication
SpringSecurityInEasySteps
Learn Spring Security step by step
Stars: ✭ 13 (-23.53%)
Mutual labels:  basic-authentication
Helmet
🐺 A Lightweight Cloud Native API Gateway.
Stars: ✭ 124 (+629.41%)
Mutual labels:  basic-authentication
bedrock-site-protect
Ansible role: Add htpasswd protection to Trellis (Bedrock-Ansible) WordPress sites.
Stars: ✭ 79 (+364.71%)
Mutual labels:  basic-authentication
static-auth
The most simple way to add Basic Authentication to a static website hosted on Vercel.
Stars: ✭ 25 (+47.06%)
Mutual labels:  basic-authentication
Go Http Tunnel
Fast and secure tunnels over HTTP/2
Stars: ✭ 2,786 (+16288.24%)
Mutual labels:  basic-authentication
aws-lambda-edge-basic-auth-terraform
A Terraform module that creates AWS Lambda@Edge resources to protect CloudFront distributions with Basic Authentication.
Stars: ✭ 18 (+5.88%)
Mutual labels:  basic-authentication
http-authentication
PSR-15 middleware to implement Basic and Digest Http authentication
Stars: ✭ 29 (+70.59%)
Mutual labels:  basic-authentication

Speedment Secure REST Example

An example project showcasing how to build a secure REST API with Speedment and Spring Boot.

Usage

Clone the project and build it using Maven.

Set up the database using this SQL code:

create database `securerest`;
use `securerest`;

create table `account` (
    `id` bigint not null auto_increment primary key,
    `username` varchar(30) not null unique,
    `password` char(60) not null,
    `role` enum('USER', 'ADMIN') not null
);

Configure the MySQL username and password in the application.properties-file in case you don't use "root" and "password" as credentials.

Start the application. The following endpoints will be mapped:

  • POST /account
  • GET /account
  • GET /account/{id}

Here are some example cURL-commands that you can try:

Register an Account
curl -X POST "http://localhost:9777/account
    ?username=my_user
    &password=my_pass"
See Information About User #1
curl -X  GET -u my_user:my_pass "http://localhost:9777/account/1"
See Information About All Users
curl -X  GET -u my_user:my_pass "http://localhost:9777/account"
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].