Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
39 commits
Select commit Hold shift + click to select a range
dbf5817
update: chrome 142 issue faq
lyzhang0113 Nov 6, 2025
facdf3f
enhance: add user guidance for Local Network Access permission in Chr…
lyzhang0113 Nov 6, 2025
7a9fda8
update: refine version-specific behavior for Chromium 142+ in trouble…
lyzhang0113 Nov 11, 2025
ba2746d
update: refine version-specific behavior details for Chromium 142 in …
lyzhang0113 Nov 12, 2025
941248e
delete: remove outdated FAQ articles on Service and WebAssembly Editions
lyzhang0113 Nov 13, 2025
e6c4865
delete: remove unused FAQ article on verifying scanner compatibility
lyzhang0113 Nov 13, 2025
4ae533b
fix links to ThumbnailViewerEvent
tony-xlh Nov 13, 2025
a792874
revamp requirements part in introduction
tony-xlh Nov 14, 2025
c2fa1de
revamp image hardware
tony-xlh Nov 14, 2025
ccbdb89
add link to supported devices by sane
tony-xlh Nov 14, 2025
1ecd805
Update imaging-hardware.md
tony-xlh Nov 14, 2025
7a52fbd
add local network access to the note of dwt initialization
tony-xlh Nov 14, 2025
3434620
remove contents in imaging-hardware
tony-xlh Nov 14, 2025
e121f0e
fix grammar mistakes in introduction
tony-xlh Nov 14, 2025
fb0dbae
Update imaging-hardware.md
tony-xlh Nov 14, 2025
188db69
fix: topchanged event description and entry
dynamsoft-h Nov 15, 2025
1e6533c
fix: broken link typo for stable release notes
dynamsoft-h Nov 15, 2025
5064301
Revert "fix: topchanged event description and entry"
tony-xlh Nov 18, 2025
c1224a3
fix: remove the mention of the topchanged event and move unbind up
tony-xlh Nov 18, 2025
00bf246
add details to chromium 142 faq's roadmap
tony-xlh Nov 18, 2025
0ff7ba3
fix mail link
tony-xlh Nov 18, 2025
9f311ce
update LNA notes about browser versions
tony-xlh Nov 24, 2025
31c3c22
update LNA FAQ's modified date
tony-xlh Nov 24, 2025
378e676
fix the spellings of properties in thumbnail viewer
tony-xlh Nov 25, 2025
0398fb0
add WIA and eSCL in imaging-hardware.md
tony-xlh Nov 26, 2025
f6022db
add other causes in the LNA FAQ
tony-xlh Nov 26, 2025
061e922
mention preserveUnmodifiedOnSave in the PDF rasterizer FAQ
tony-xlh Nov 26, 2025
a6e343d
update modified date
tony-xlh Nov 26, 2025
fbd0728
Update imaging-hardware.md
tony-xlh Nov 26, 2025
81a83df
Merge pull request #952 from dynamsoft-docs/preview-19.3
tony-xlh Dec 1, 2025
d367826
set noTitleIndex and needGenerateH3Content for OCR guide
tony-xlh Dec 1, 2025
e35c179
update OCR system requirement
tony-xlh Dec 1, 2025
ad37977
update latest version 19.3
tony-xlh Dec 1, 2025
a70ad78
add EnableLocalNetworkMixedContent in index.md
tony-xlh Dec 1, 2025
c52e5ca
move the noTitleIndex and needGenerateH3Content to OCR guide
tony-xlh Dec 1, 2025
7034cd8
add methods table in OCR api docs
tony-xlh Dec 1, 2025
1f226a5
add OCR API in the side menu
tony-xlh Dec 1, 2025
82ecebf
add OCR guide to index.md
tony-xlh Dec 1, 2025
5812e8c
update return value of GetInstalledOCRInfo
tony-xlh Dec 1, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion _articles/extended-usage/ocr.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
---
layout: default-layout
needAutoGenerateSidebar: true
needGenerateH3Content: true
noTitleIndex: true
title: Dynamic Web TWAIN SDK Features - OCR
keywords: Dynamic Web TWAIN, Documentation, OCR
breadcrumbText: OCR
Expand All @@ -13,7 +15,7 @@ Dynamic Web TWAIN provides an OCR add-on to extract text in your scanned images.

## Requirements

* Windows 10+
* Windows 10 versions >= 1809 and all versions of Windows 11
* A license with the OCR module

## How to Use
Expand Down
116 changes: 97 additions & 19 deletions _articles/faq/chromium-142-local-network-access-issue.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ keywords: Dynamic Web TWAIN, Error Troubleshooting, CORS, unknown address space,
breadcrumbText: Error message - Permission was denied for this request to access the unknown address space
description: CORS unknown address space
date: 2025-11-04 17:21:42 +0800
last_modified: 2025-11-05 17:26:42 +0800
last_modified: 2025-11-26 15:46:00 +0800
---

# Error Troubleshooting
Expand All @@ -25,18 +25,38 @@ Starting in **Chromium-based browsers v142+** (released Oct 28, 2025)—includin

You may experience one or more of the following:

***1. Service installer repeatedly prompted***
#### **1) Browser repeatedly prompts to download the service**
The browser asks the user to download/install the Dynamsoft Web TWAIN Service even though it is already installed.

The browser prompts you to download/install the service even though it is already installed.
![DWT_installer.png](/assets/imgs/DWT_installer.png)

***2. Initialization succeeds, but scan/load shows blank images***
#### **2) Initialization succeeds, but scanning / loading returns blank**
Initialization appears successful, but scanned or loaded images are blank.

The browser console (F12 → Console) may show a CORS denial similar to:

The browser console (F12 → Console) shows a CORS rejection similar to:
```shell
Access to fetch at 'https://127.0.0.1:18623/fa/VersionInfo?ts=1761893667670' from origin 'https://your-domain.com' has been blocked by CORS policy: Permission was denied for this request to access the `unknown` address space.
Access to fetch at 'https://127.0.0.1:18623/fa/VersionInfo?ts=1761893667670'
from origin 'https://your-domain.com' has been blocked by CORS policy:
Permission was denied for this request to access the `unknown` address space.
```

---

#### Version-Specific Behavior

The observed behavior depends on Chromium browser version and Dynamic Web TWAIN (DWT) version:

| Browser Version | DWT Version | Resulting Symptom |
|-------------------|------------------|-----------------------------|
| Chromium 142 | < 18.5.0 | Download Prompt |
| Chromium 142 | ≥ 18.5.0 | Blank Images after Scanning |
| Chromium 145+ (*) | Any | Download Prompt |

> (*) **Chromium 145, which can also block websocket, has not been officially released.**
> Behavior is based on pre-release testing and may change once the final release becomes available.
> Edge 143 and Firefox Nightly will have local network permission control as well.

### Root Cause

Chromium 142 introduces a new [Local Network Access security policy](https://chromestatus.com/feature/5152728072060928) requirement.
Expand Down Expand Up @@ -67,27 +87,85 @@ Please refer to:

***3. Developer Notes***

**a) Check Permission Programmatically**
**a) If Running Inside an `iframe`**

```javascript
let status = await navigator.permissions.query({ name: "local-network-access" });
console.log(status.state);
```
> [!IMPORTANT]
> If Dynamic Web TWAIN is running inside an iframe from a different origin (cross-origin), you must explicitly grant local-network access in the iframe.
> If the iframe is same-origin, no additional configuration is required.

If not granted, guide users to:
To enable access, specify the `allow` attribute.
For security reasons, it is recommended to allow only the necessary origin rather than using a wildcard.

Chrome → Settings → Privacy and Security → Site Settings → Local network access
```html
<!-- Recommended: restrict to specific origin -->
<iframe src="..." allow="local-network-access your-domain.com"></iframe>

**b) If Running Inside an `iframe`**
<!-- Not recommended: wildcard -->
<!-- <iframe src="..." allow="local-network-access *"></iframe> -->
```

> [!IMPORTANT]
> If your site is embedded in an iframe, you MUST explicitly allow local-network access.
**b) (Optional Enhancement) Permission Check for Improved UX**

Please explicitly allow `local-network-access` in the attributes of the iframe:
```html
<iframe src="..." allow="local-network-access *"></iframe>
You can optionally query Local Network Access permission at runtime.
This isn’t required, but implementing a check can help you proactively notify users and provide clearer guidance if permission is missing.
```javascript
// Before initializing Dynamsoft WebTWAIN (DWT), you can remind users
// that Chrome may ask for Local Network Access permission.
(async () => {
try {
const result = await navigator.permissions.query({ name: "local-network-access" });
console.log(`LNA permission state: ${result.state}`);

const state = result.state; // 'denied', 'prompt', 'granted'

if (state === "denied") {
const currentSite = encodeURIComponent(window.location.origin);
const settingsUrl = `chrome://settings/content/siteDetails?site=${currentSite}`;
console.log(`Local network access is currently denied.\n\nPlease go to:\n${settingsUrl}\nand enable 'Local network access' permission for this site.`);
// Optionally show a UI guide or help link here.
} else if (state === "prompt") {
alert("To connect with the local scanning service, Chrome will ask for 'Local network access' permission.\n\nPlease click 'Allow' when prompted.");
// Proceed to init DWT after this message.
// e.g., Dynamsoft.DWT.Load() or CreateDWTObjectEx or your init DWT function
} else if (state === "granted") {
console.log("Local network access already granted.");
// Initialize DWT or proceed directly.
// e.g., Dynamsoft.DWT.Load() or CreateDWTObjectEx or your init DWT function
} else {
console.log("Unexpected LNA state:", state);
}

} catch (e) {
console.log("This browser does not support Chromium LNA Permissions API yet.");
// Fallback: directly initialize DWT
// Dynamsoft.DWT.Load() or CreateDWTObjectEx or your init DWT function
}
})();
```
If the permission is not granted, consider displaying a user-friendly message directing them to:

> Chrome → Settings → Privacy and Security → Site Settings → Local network access

This approach provides a more polished user experience, especially during onboarding or troubleshooting.

### Roadmap

Dynamsoft plans to add a feature that automatically detects local service connectivity and permission status. If the connection is blocked, users will be prompted with a message and directed to this FAQ page.

Here are the details:

* When local network access is blocked, prompt the user with the following dialog:

![prompt blocked](/assets/imgs/local-network-access/prompt-blocked.jpg)

* Add a sentence about the permission in the service installation dialog, since we cannot determine whether the connection failure is due to the service not being installed or the access being blocked.

![prompt blocked](/assets/imgs/local-network-access/service-installation-dialog.png)

Clicking "Guide" will open the dialog shown above.

This design will be integrated in v19.3. For old versions, we can include an extra js file, which can be retrieved by contacting [support](mailto://support@dynamsoft.com).

## Other Causes

There are other causes of service not being connected. You can find them in [another FAQ](/_articles/faq/service-prompting-to-install-repeatedly.md).
21 changes: 0 additions & 21 deletions _articles/faq/difference-in-service-and-webassembly-editions.md

This file was deleted.

2 changes: 1 addition & 1 deletion _articles/faq/upgrade-to-latest-version.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ Please refer to the upgrade guide and the release notes below to update your app

[Dynamic Web TWAIN Development - Upgrade Guide](/_articles/indepth/development/upgrade.md){:target="_blank"}

[Dynamic Web TWAIN Schedule - Stable Release](/_articles/info/schedule/stable.md){:target="_blank"}
[Dynamic Web TWAIN Schedule - Stable Release](/_articles/info/schedule/Stable.md){:target="_blank"}

Once you are ready to upgrade, please send an email to <a href="mailto:sales@dynamsoft.com">sales@dynamsoft.com</a> requesting the upgrade be done.

Expand Down
23 changes: 0 additions & 23 deletions _articles/faq/use-webassembly-to-support-webcam.md

This file was deleted.

68 changes: 0 additions & 68 deletions _articles/faq/verify-if-device-is-supported.md

This file was deleted.

6 changes: 4 additions & 2 deletions _articles/faq/when-is-pdf-rasterizer-needed.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ keywords: Dynamic Web TWAIN, Addon, pdf rasterizer
breadcrumbText: When do I need PDF Rasterizer Addon? Can I load existing PDF files into the Dynamic Web TWAIN SDK without the PDF Rasterizer addon?
description: When do I need PDF Rasterizer Addon? Can I load existing PDF files into the Dynamic Web TWAIN SDK without the PDF Rasterizer addon?
date: 2021-12-01 01:09:41 +0800
last_modified: 2025-01-15 14:58:40 +0800
last_modified: 2025-11-26 15:58:40 +0800
---

# Addon
Expand All @@ -16,4 +16,6 @@ last_modified: 2025-01-15 14:58:40 +0800

Third-party generated PDF files may house multiple images, text, or annotations in a single PDF page. As these elements must be rendered within the Dynamic Web TWAIN, it will utilize the PDF rasterizer addon.

When importing a PDF file generated by Dynamic Web TWAIN, or if each page of a third-party PDF holds nothing but a single, unadulterated image, there's no need for the PDF rasterizer addon.
When importing a PDF file generated by Dynamic Web TWAIN, or if each page of a third-party PDF holds nothing but a single image, there's no need for the PDF rasterizer addon.

If you need to append images to an existing PDF and want to keep the original pages instead of rasterized images in the saved PDF, you need to enable the [`preserveUnmodifiedOnSave`](/_articles/info/api/interfaces.md#:~:text=preserveUnmodifiedOnSave){:target="_blank"} property.
2 changes: 1 addition & 1 deletion _articles/general-usage/initialization.md
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ For demonstration purposes, save the sample in an HTML file (e.g. `helloWorld.ht

Otherwise, click [here](/_articles/general-usage/server-deployment.md) to learn how to deploy DWT on your web server.

> If your environment does not have **Dynamic Web TWAIN Service** installed, a prompt will appear to ask you to install the service. You can learn more about what the service does [here](/_articles/faq/what-does-dynamsoft-service-do-on-end-user-machine.md).
> If your environment does not have **Dynamic Web TWAIN Service** installed or local network access is not granted, a prompt will appear to ask you to install the service. You can learn more about what the service does [here](/_articles/faq/what-does-dynamsoft-service-do-on-end-user-machine.md).
Below is more detail on what happens during initialization and how to retrieve the `WebTwain` object.

Expand Down
1 change: 1 addition & 0 deletions _articles/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@ description: Dynamic Web TWAIN SDK Documentation Homepage
- [Using the DWT RESTful API]({{site.extended-usage}}restful-api.html)
- [Barcode Recognition]({{site.extended-usage}}barcode-processing.html)
- [PDF Handling]({{site.extended-usage}}pdf-processing.html)
- [OCR](/_articles/extended-usage/ocr.md)
<!--- [PDF Compressor (Beta)]({{site.extended-usage}}pdf-compression.html)-->
- [Remote Scan](https://www.dynamsoft.com/remote-scan/docs/introduction/)
- [Configuring System Messages]({{site.extended-usage}}system-message-configuration.html)
Expand Down
5 changes: 4 additions & 1 deletion _articles/info/api/Addon_OCR.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,9 @@ description: Dynamic Web TWAIN SDK Documentation API Reference OCR Addon APIs Pa

**Methods**

| [`GetInstalledOCRInfo()`](#getinstalledocrinfo) | [`DetectPageOrientation()`](#detectpageorientation) | [`Recognize()`](#recognize) | [`SaveToPath()`](#savetopath) |
| [`SaveAsBase64()`](#saveasbase64) | [`SaveAsBlob()`](#saveasblob) | | |

---

## GetInstalledOCRInfo()
Expand All @@ -27,7 +30,7 @@ GetInstalledOCRInfo(): Promise<OCRInfo>;

**Return Values**

An [`OCRInfo`](/_articles/info/api/interfaces.md#ocrinfo) object.
Promise of an [`OCRInfo`](/_articles/info/api/interfaces.md#ocrinfo) object.

**Availability**

Expand Down
Loading