<html xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="Generator" content="Microsoft Word 15 (filtered medium)">
<style><!--
/* Font Definitions */
@font-face
{font-family:Wingdings;
panose-1:5 0 0 0 0 0 0 0 0 0;}
@font-face
{font-family:"Cambria Math";
panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
{font-family:Calibri;
panose-1:2 15 5 2 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{margin:0cm;
margin-bottom:.0001pt;
font-size:12.0pt;
font-family:"Calibri",sans-serif;
mso-fareast-language:EN-US;}
p.MsoListParagraph, li.MsoListParagraph, div.MsoListParagraph
{mso-style-priority:34;
margin-top:0cm;
margin-right:0cm;
margin-bottom:0cm;
margin-left:36.0pt;
margin-bottom:.0001pt;
font-size:12.0pt;
font-family:"Calibri",sans-serif;
mso-fareast-language:EN-US;}
span.EmailStyle17
{mso-style-type:personal-compose;
font-family:"Calibri",sans-serif;
color:windowtext;}
.MsoChpDefault
{mso-style-type:export-only;
mso-fareast-language:EN-US;}
@page WordSection1
{size:612.0pt 792.0pt;
margin:72.0pt 72.0pt 72.0pt 72.0pt;}
div.WordSection1
{page:WordSection1;}
/* List Definitions */
@list l0
{mso-list-id:1673144267;
mso-list-type:hybrid;
mso-list-template-ids:-2019760148 134807553 134807555 134807557 134807553 134807555 134807557 134807553 134807555 134807557;}
@list l0:level1
{mso-level-number-format:bullet;
mso-level-text:;
mso-level-tab-stop:none;
mso-level-number-position:left;
text-indent:-18.0pt;
font-family:Symbol;}
@list l0:level2
{mso-level-number-format:bullet;
mso-level-text:o;
mso-level-tab-stop:none;
mso-level-number-position:left;
text-indent:-18.0pt;
font-family:"Courier New";}
@list l0:level3
{mso-level-number-format:bullet;
mso-level-text:;
mso-level-tab-stop:none;
mso-level-number-position:left;
text-indent:-18.0pt;
font-family:Wingdings;}
@list l0:level4
{mso-level-number-format:bullet;
mso-level-text:;
mso-level-tab-stop:none;
mso-level-number-position:left;
text-indent:-18.0pt;
font-family:Symbol;}
@list l0:level5
{mso-level-number-format:bullet;
mso-level-text:o;
mso-level-tab-stop:none;
mso-level-number-position:left;
text-indent:-18.0pt;
font-family:"Courier New";}
@list l0:level6
{mso-level-number-format:bullet;
mso-level-text:;
mso-level-tab-stop:none;
mso-level-number-position:left;
text-indent:-18.0pt;
font-family:Wingdings;}
@list l0:level7
{mso-level-number-format:bullet;
mso-level-text:;
mso-level-tab-stop:none;
mso-level-number-position:left;
text-indent:-18.0pt;
font-family:Symbol;}
@list l0:level8
{mso-level-number-format:bullet;
mso-level-text:o;
mso-level-tab-stop:none;
mso-level-number-position:left;
text-indent:-18.0pt;
font-family:"Courier New";}
@list l0:level9
{mso-level-number-format:bullet;
mso-level-text:;
mso-level-tab-stop:none;
mso-level-number-position:left;
text-indent:-18.0pt;
font-family:Wingdings;}
ol
{margin-bottom:0cm;}
ul
{margin-bottom:0cm;}
--></style>
</head>
<body lang="en-DE" link="#0563C1" vlink="#954F72">
<div class="WordSection1">
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt">Dear all,<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt">I am uncertain how to properly configure slurmrestd to just validate JWTs and do not use other mechanisms.<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt">My setup and observations:<o:p></o:p></span></p>
<ul style="margin-top:0cm" type="disc">
<li class="MsoListParagraph" style="margin-left:0cm;mso-list:l0 level1 lfo1"><span lang="EN-US" style="font-size:11.0pt">I use slurm 20.02: https://download.schedmd.com/slurm/slurm-20.02.0.tar.bz2<o:p></o:p></span></li><li class="MsoListParagraph" style="margin-left:0cm;mso-list:l0 level1 lfo1"><span lang="EN-US" style="font-size:11.0pt">I start it with systemd under root-user as follows: slurmrestd -f /etc/slurm/slurm.conf -u slurmrestd -g users 0.0.0.0:8080 -vvvvvvvv<o:p></o:p></span></li><li class="MsoListParagraph" style="margin-left:0cm;mso-list:l0 level1 lfo1"><span lang="EN-US" style="font-size:11.0pt">Env-variable SLURM_JWT is not populated<o:p></o:p></span></li><li class="MsoListParagraph" style="margin-left:0cm;mso-list:l0 level1 lfo1"><span lang="EN-US" style="font-size:11.0pt">Slurm.conf contains:
<o:p></o:p></span></li><ul style="margin-top:0cm" type="circle">
<li class="MsoListParagraph" style="margin-left:0cm;mso-list:l0 level2 lfo1"><span lang="EN-US" style="font-size:11.0pt">AuthType=auth/munge
<br>
AuthAltTypes=auth/jwt<o:p></o:p></span></li></ul>
<li class="MsoListParagraph" style="margin-left:0cm;mso-list:l0 level1 lfo1"><span lang="EN-US" style="font-size:11.0pt">Observations:<o:p></o:p></span></li><ul style="margin-top:0cm" type="circle">
<li class="MsoListParagraph" style="margin-left:0cm;mso-list:l0 level2 lfo1"><span lang="EN-US" style="font-size:11.0pt">I can pass invalid tokens via X-SLURM-USER-TOKEN and still get results and no 401<o:p></o:p></span></li><li class="MsoListParagraph" style="margin-left:0cm;mso-list:l0 level2 lfo1"><span lang="EN-US" style="font-size:11.0pt">slumrestd writes at startup:
<o:p></o:p></span></li><ul style="margin-top:0cm" type="square">
<li class="MsoListParagraph" style="margin-left:0cm;mso-list:l0 level3 lfo1"><span lang="EN-US" style="font-size:11.0pt">debug3: init_rest_auth: AUTH_TYPE_LOCAL activated<o:p></o:p></span></li><li class="MsoListParagraph" style="margin-left:0cm;mso-list:l0 level3 lfo1"><span lang="EN-US" style="font-size:11.0pt">debug3: init_rest_auth: AUTH_TYPE_USER_PSK activated<o:p></o:p></span></li></ul>
</ul>
</ul>
<p class="MsoNormal"><span lang="EN-US"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-US"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-US">What might be flawed with my config? How to just use JWT-Tokens for auth and reject request in case of invalid tokens?<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US">I have the feeling as if the JWT-Validation is still bypassed.<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-US"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-US">Thanks in advance,<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US">Stephen<o:p></o:p></span></p>
</div>
<p><span style="FONT-SIZE: 12pt; FONT-FAMILY: Calibri">Henkel AG & Co. KGaA<br>
Sitz: 40191 Düsseldorf, Deutschland<br>
Handelsregister: Amtsgericht Düsseldorf, HRB 4724<br>
Vorsitzende des Aufsichtsrats: Dr. Simone Bagel-Trah<br>
<br>
Persönlich haftende Gesellschafterin:<br>
Henkel Management AG<br>
Sitz: 40191 Düsseldorf; Deutschland<br>
Handelsregister: Amtsgericht Düsseldorf, HRB 58139<br>
Aufsichtsratsvorsitzende: Dr. Simone Bagel-Trah<br>
Vorstand: Carsten Knobel (Vorsitzender),<br>
Jan-Dirk Auris, Sylvie Nicol,<br>
Bruno Piacenza, Jens-Martin Schwärzler, Marco Swoboda<br>
</span></p>
</body>
</html>