Opened 9 years ago

Closed 4 years ago

#12954 closed enhancement (patchwelcome)

dojox.math.BigInteger - replace references to navigator.appName with feature tests

Reported by: ben hockey Owned by: Eugene Lazutkin
Priority: low Milestone: 1.13
Component: Dojox Version: 1.6.1
Keywords: Cc:
Blocked By: Blocking:

Description

dojox.math.BigInteger? has a couple of references to navigator.appName. given that this code (and code that uses this, specifically dojox.encoding.crypto.RSAkey) is likely to be useful outside of the browser, if possible, replacing references to navigator with feature detection is probably desirable.

Change History (5)

comment:1 Changed 9 years ago by Adam Peller

Owner: changed from Adam Peller to Tom Trenka

comment:2 Changed 9 years ago by ben hockey

fwiw, i took a look at http://www-cs-students.stanford.edu/~tjw/jsbn/ to get some insight as to the use cases for the different paths and it seems that its for performance reasons and is based on what seemed to work the fastest in particular browsers. testing which path is fastest for a particular browser might not be something to be feature tested but a check for if we're in the browser before referencing navigator should help. i'll work on a patch that guards the reference to navigator and defaults to the current else block for all cases other than the 2 specific ones tested for.

comment:3 Changed 8 years ago by Tom Trenka

Owner: changed from Tom Trenka to uhop
Priority: highlow
Status: newassigned

Reassigning to Eugene, who wrote the code.

comment:4 Changed 8 years ago by Adam Peller

Owner: changed from uhop to Eugene Lazutkin

comment:5 Changed 4 years ago by dylan

Milestone: tbd1.12
Resolution: patchwelcome
Status: assignedclosed

Given that no one has shown interest in creating a patch in the past 4+ years, I'm closing this as patchwelcome.

Note: See TracTickets for help on using tickets.