<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: DUO and angular in APIs</title>
    <link>https://community.cisco.com/t5/apis/duo-and-angular/m-p/4884375#M578</link>
    <description>&lt;DIV class="duo-migrated-content"&gt;&lt;P&gt;Hi Andrea,&lt;/P&gt;
&lt;P&gt;Thank you so much for following up here in the community to share the answer you found with others! I’m glad you got the solution you were looking for. &lt;IMG width="20" height="20" src="https://community.cisco.com/legacyfs/online/ciscoduo/cdn_emojis/twitter/slight_smile.png" style="display : inline;" /&gt;&lt;/P&gt;
&lt;P&gt;FYI I am going to relabel this to our “Web SDK” category since it’s just a bit more specific to the exact issue you describe. Although “Protecting applications” makes sense and is relevant too, this will help others find the answer too in the future!&lt;/P&gt;&lt;/DIV&gt;</description>
    <pubDate>Mon, 14 Dec 2020 12:39:00 GMT</pubDate>
    <dc:creator>Amy2</dc:creator>
    <dc:date>2020-12-14T12:39:00Z</dc:date>
    <item>
      <title>DUO and angular</title>
      <link>https://community.cisco.com/t5/apis/duo-and-angular/m-p/4884372#M575</link>
      <description>&lt;DIV class="duo-migrated-content"&gt;&lt;P&gt;Hello,&lt;/P&gt;
&lt;P&gt;we are developing a prototype portal using angular as front-end and django restframework as backend. Duo authentication has just been added and we successfully receive/acknowledge the duo push requests.&lt;/P&gt;
&lt;P&gt;There is one issue though… upon the duo push acknowledge the Web SDK issue back a POST message with the sig_response but angular framework only deals with GET hence it fails with a “Cannot POST /login” error message.&lt;/P&gt;
&lt;P&gt;How can we configure duo’s callback action to avoid POST and just load a different page instead ?&lt;/P&gt;
&lt;P&gt;Thx,&lt;BR /&gt;
Andrea&lt;/P&gt;&lt;/DIV&gt;</description>
      <pubDate>Fri, 04 Dec 2020 13:42:46 GMT</pubDate>
      <guid>https://community.cisco.com/t5/apis/duo-and-angular/m-p/4884372#M575</guid>
      <dc:creator>abuzzi</dc:creator>
      <dc:date>2020-12-04T13:42:46Z</dc:date>
    </item>
    <item>
      <title>Re: DUO and angular</title>
      <link>https://community.cisco.com/t5/apis/duo-and-angular/m-p/4884373#M576</link>
      <description>&lt;DIV class="duo-migrated-content"&gt;&lt;P&gt;Hello,&lt;/P&gt;
&lt;P&gt;issue solved.&lt;/P&gt;
&lt;P&gt;Looking at the Duo-Web-v2.js I realized that an hidden form is created upon duo push acknoledge.&lt;BR /&gt;
If we define a submit_callback during the Duo.init this avoid the hidden’s form submit and give control back to the code.&lt;BR /&gt;
Below you see I can dump the sig_response and based on that verify and handle 2FA consequently.&lt;/P&gt;
&lt;P&gt;Thx.&lt;BR /&gt;
A.&lt;/P&gt;
&lt;PRE&gt;&lt;CODE&gt;Duo.init({
  iframe: "duo_iframe",
  host: "■■■■■■■■■■■■■■■■■■■■■■■■■■■",
  sig_request: this.duo_sign_request,
  submit_callback: (data:any) =&amp;gt; {
    var elem = document.getElementsByName('sig_response');
    var sig_response = elem[0].getAttribute('value');
    console.log(sig_response)
  },
});&lt;/CODE&gt;&lt;/PRE&gt;&lt;/DIV&gt;</description>
      <pubDate>Sat, 05 Dec 2020 13:12:35 GMT</pubDate>
      <guid>https://community.cisco.com/t5/apis/duo-and-angular/m-p/4884373#M576</guid>
      <dc:creator>abuzzi</dc:creator>
      <dc:date>2020-12-05T13:12:35Z</dc:date>
    </item>
    <item>
      <title>Re: DUO and angular</title>
      <link>https://community.cisco.com/t5/apis/duo-and-angular/m-p/4884374#M577</link>
      <description>&lt;DIV class="duo-migrated-content"&gt;&lt;P&gt;fyi…&lt;/P&gt;
&lt;P&gt;fully working example:&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;DevNet Code Exchange: abuzzi-cisco/angular-duo is now published&lt;/STRONG&gt;&lt;BR /&gt;
&lt;/P&gt;&lt;ASIDE class="onebox allowlistedgeneric"&gt;
  &lt;HEADER class="source"&gt;
      &lt;IMG src="https://developer.cisco.com/img/favicon.ico" class="site-icon" width="16" height="16" /&gt;
      &lt;A href="https://developer.cisco.com/codeexchange/github/repo/abuzzi-cisco/angular-duo" target="_blank" rel="noopener nofollow ugc"&gt;developer.cisco.com&lt;/A&gt;
  &lt;/HEADER&gt;
  &lt;ARTICLE class="onebox-body"&gt;
    &lt;IMG src="https://community.cisco.com/" class="thumbnail" width="16" height="16" /&gt;

&lt;H3&gt;&lt;A href="https://developer.cisco.com/codeexchange/github/repo/abuzzi-cisco/angular-duo" target="_blank" rel="noopener nofollow ugc"&gt;Cisco DevNet Code Exchange: Discover code repositories related to Cisco...&lt;/A&gt;&lt;/H3&gt;



  &lt;/ARTICLE&gt;
  &lt;DIV class="onebox-metadata"&gt;
    
    
  &lt;/DIV&gt;
  &lt;DIV style="clear: both"&gt;&lt;/DIV&gt;
&lt;/ASIDE&gt;

&lt;P&gt;Thx,&lt;BR /&gt;
A.&lt;/P&gt;&lt;/DIV&gt;</description>
      <pubDate>Sat, 12 Dec 2020 13:51:24 GMT</pubDate>
      <guid>https://community.cisco.com/t5/apis/duo-and-angular/m-p/4884374#M577</guid>
      <dc:creator>abuzzi</dc:creator>
      <dc:date>2020-12-12T13:51:24Z</dc:date>
    </item>
    <item>
      <title>Re: DUO and angular</title>
      <link>https://community.cisco.com/t5/apis/duo-and-angular/m-p/4884375#M578</link>
      <description>&lt;DIV class="duo-migrated-content"&gt;&lt;P&gt;Hi Andrea,&lt;/P&gt;
&lt;P&gt;Thank you so much for following up here in the community to share the answer you found with others! I’m glad you got the solution you were looking for. &lt;IMG width="20" height="20" src="https://community.cisco.com/legacyfs/online/ciscoduo/cdn_emojis/twitter/slight_smile.png" style="display : inline;" /&gt;&lt;/P&gt;
&lt;P&gt;FYI I am going to relabel this to our “Web SDK” category since it’s just a bit more specific to the exact issue you describe. Although “Protecting applications” makes sense and is relevant too, this will help others find the answer too in the future!&lt;/P&gt;&lt;/DIV&gt;</description>
      <pubDate>Mon, 14 Dec 2020 12:39:00 GMT</pubDate>
      <guid>https://community.cisco.com/t5/apis/duo-and-angular/m-p/4884375#M578</guid>
      <dc:creator>Amy2</dc:creator>
      <dc:date>2020-12-14T12:39:00Z</dc:date>
    </item>
  </channel>
</rss>

