[km] Strings longer than allowed in pipnss.properties

RESOLVED FIXED

Status

Mozilla Localizations
km / Khmer
RESOLVED FIXED
a month ago
8 days ago

People

(Reporter: flod, Assigned: flod)

Tracking

Firefox Tracking Flags

(Not tracked)

Details

(Assignee)

Description

a month ago
pipnss.properties includes a few special strings with hard length limits
https://hg.mozilla.org/l10n/gecko-strings/file/default/security/manager/chrome/pipnss/pipnss.properties#l10

Once converted to UTF-8, the string needs to be shorter than the specified limit (32 or 64 bytes), otherwise it will be truncated in the interface.

There are currently some strings in your localization that exceed this limit and need to be fixed:

- Fips140SlotDescription (សេវា​វិញ្ញាបនបត្រ និង​គន្លឹះ​ពាក្យ​នៃ​វិទ្យា​គ្រីប FIPS 140) is longer than 64 bytes (current length: 157 bytes)
- Fips140TokenDescription (ឧបករណ៍​សុវត្ថិភាព​ផ្នែក​ទន់ (FIPS)) is longer than 32 bytes (current length: 88 bytes)
- InternalToken (ឧបករណ៍​សុវត្ថិភាព​ផ្នែក​ទន់) is longer than 32 bytes (current length: 81 bytes)
- LibraryDescription (សេវា​នៃ​ការ​គ្រីប​ខាង​ក្នុង​របស់ PSM) is longer than 32 bytes (current length: 100 bytes)
- RootCertModuleName (ម៉ូឌុល Roots ដែល​មាន​ជាប់​មក​ជាមួយ) is longer than 64 bytes (current length: 88 bytes)
- SlotDescription (សេវា​នៃ​វិទ្យា​គ្រីប​​ខាង​ក្នុង​របស់ ​PSM) is longer than 64 bytes (current length: 115 bytes)
- TokenDescription (សេវា​នៃ​ការ​គ្រីប​ទូទៅ) is longer than 32 bytes (current length: 66 bytes)
- TokenDescription (សេវា​នៃ​ការ​គ្រីប​ទូទៅ) is longer than 32 bytes (current length: 66 bytes)

Strings are available in this file in Pontoon
https://pontoon.mozilla.org/km/firefox/security/manager/chrome/pipnss/pipnss.properties/

***
HOW TO FIX THIS BUG

To check the length of a string, you can use the Browser Console in Firefox:
1. Open Tools->Web Developer->Browser Console
2. In the input field at the bottom of the window copy and paste the following code, replacing YOURSTRING with your actual translation, keeping the surrounding quotes

(new TextEncoder('utf-8').encode('YOURSTRING')).length

3. Press enter

The number displayed is the current string length.

One important consideration: it might be impossible for some languages to come up with a reasonable translation within these limits, since the length in bytes does not match the length in characters. For example: "cookie" is 6 bytes, "కుకీలు" is 18 bytes.

In this case, it's better to keep the English text than a translation that won't be understandable because of truncations.
(Assignee)

Comment 1

a month ago
Updated list:

- Fips140SlotDescription (សេវា​វិញ្ញាបនបត្រ និង​គន្លឹះ​ពាក្យ​នៃ​វិទ្យា​គ្រីប FIPS 140) is longer than 64 bytes (current length: 157 bytes)
- Fips140TokenDescription (ឧបករណ៍​សុវត្ថិភាព​ផ្នែក​ទន់ (FIPS)) is longer than 32 bytes (current length: 88 bytes)
- InternalToken (ឧបករណ៍​សុវត្ថិភាព​ផ្នែក​ទន់) is longer than 32 bytes (current length: 81 bytes)
- LibraryDescription (សេវា​នៃ​ការ​គ្រីប​ខាង​ក្នុង​របស់ PSM) is longer than 32 bytes (current length: 100 bytes)
- PrivateTokenDescription (ឧបករណ៍​សុវត្ថិភាព​ផ្នែក​ទន់) is longer than 32 bytes (current length: 81 bytes)
- RootCertModuleName (ម៉ូឌុល Roots ដែល​មាន​ជាប់​មក​ជាមួយ) is longer than 64 bytes (current length: 88 bytes)
- SlotDescription (សេវា​នៃ​វិទ្យា​គ្រីប​​ខាង​ក្នុង​របស់ ​PSM) is longer than 64 bytes (current length: 115 bytes)
- TokenDescription (សេវា​នៃ​ការ​គ្រីប​ទូទៅ) is longer than 32 bytes (current length: 66 bytes)
(Assignee)

Comment 2

8 days ago
I'm going to revert all these strings (10) to English, since it doesn't seem possible to produce a meaningful translation in some languages using non Latin scripts.
Assignee: nobody → francesco.lodolo
Status: NEW → RESOLVED
Last Resolved: 8 days ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.