Problem/Motivation

Steps to reproduce

Proposed resolution

Remaining tasks

User interface changes

API changes

Data model changes

Issue fork alogin-3416397

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

santhosh-kumar-rengasamy’s picture

santhosh-kumar-rengasamy’s picture

StatusFileSize
new653 bytes

Please try this patch for QA generation.

santhosh-kumar-rengasamy’s picture

StatusFileSize
new653 bytes

The below patch has been created for the version (2.0.x).
Please verify.

ahmed.raza’s picture

Status: Active » Postponed (maintainer needs more info)

I've tested this on fresh Drupal 10 setup and couldn't reproduce. It works as designed.

Need more details on your module and drupal version and steps to reproduce.

Tested this on module version 2.0.8
Drupal version 10.2.8
PHP version 8.1

ahmed.raza’s picture

StatusFileSize
new154.83 KB
awolfey’s picture

Status: Postponed (maintainer needs more info) » Reviewed & tested by the community

I have the same problem. Without the image tag the raw png data is printed.
data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAA.....
The patch fixes this for me.

awolfey’s picture

Module version: 2.0.8
Drupal: 10.1.4
PHP: 8.1

ahmed.raza’s picture

Again, the issue is not reproducable to me, Checked on fresh drupal installation. The code

`$authenticator->getQr()` returns svg structure, your patch is wrong svg structure cannot be put into < img src="[svg_code_here]" >.

The issue is not reproducable in the first place. Both of you try reinstalling the module.

ahmed.raza’s picture

Status: Reviewed & tested by the community » Closed (works as designed)
awolfey’s picture

@ahmed, it looks like you're expecting an svg, but I'm getting a png. What kind of image toolkit and settings are you using? PNG does work here < img src="[encoded_png_code_here]" >, which is why this patch works for me. Thanks.

I've updated the module to the latest version, and reinstalled it. Core is now 10.2.4.

blade_ukraine’s picture

StatusFileSize
new705 bytes

Here is one extra solution that will work with both types of generated qr-code encoding png to base64 and svg.

blade_ukraine’s picture

blade_ukraine’s picture

StatusFileSize
new730 bytes

Fixed 2 type qr codes display patch

blade_ukraine’s picture

@awolfey In my case, the situation is worse. Locally, I have SVG, on the server, I have PNG. Based on that, I've created patch #14

blade_ukraine’s picture

Status: Closed (works as designed) » Needs review
rajdip_755’s picture

Assigned: Unassigned » rajdip_755

rajdip_755 changed the visibility of the branch 3416397-qr-code-is to hidden.

rajdip_755’s picture

StatusFileSize
new348.57 KB
new77.99 KB

Hi all,

I have successfully replicated the issue and for solving it, applied the patch attached in #14 .

This patch successfully fixed the QR code generation issue. I'm attaching here the screenshots of the config form before and after applying the patch respectively.
QR-before
QR-after

Along with that, I've converted the patch as MR also.

Thanks !

rajdip_755’s picture

Assigned: rajdip_755 » Unassigned
Status: Needs review » Reviewed & tested by the community

ahmed.raza’s picture

ahmed.raza’s picture

Status: Reviewed & tested by the community » Fixed

Those facing this issue, update the module to latest version.

@blade_ukraine, thanks for the patch its merged.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.