File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -28,7 +28,7 @@ function HorseBasicAuthentication(const AAuthenticate: THorseBasicAuthentication
2828
2929procedure Middleware (Req: THorseRequest; Res: THorseResponse; Next: TProc);
3030const
31- BASIC_AUTH = ' Basic ' ;
31+ BASIC_AUTH = ' basic ' ;
3232var
3333 LBasicAuthenticationEncode: string;
3434 LBasicAuthenticationDecode: TStringList;
@@ -39,7 +39,7 @@ procedure Middleware(Req: THorseRequest; Res: THorseResponse; Next: TProc);
3939 Res.Send(' Authorization not found' ).Status(401 );
4040 raise EHorseCallbackInterrupted.Create;
4141 end ;
42- if not LBasicAuthenticationEncode.StartsWith(BASIC_AUTH) then
42+ if not LBasicAuthenticationEncode.ToLower. StartsWith(BASIC_AUTH) then
4343 begin
4444 Res.Send(' Invalid authorization type' ).Status(401 );
4545 raise EHorseCallbackInterrupted.Create;
You can’t perform that action at this time.
0 commit comments