servo/components/script/dom
bors-servo c022262826 Auto merge of #6505 - ttaubert:issue/4666-crypto-getRandomValues, r=Ms2ger
Implement crypto.getRandomValues()

Didn't touch mozjs or rust-mozjs because implementing that in the code generator didn't seem too easy. I'm using the same workaround that the TextDecoder does.

Using the OsRng should be the right choice here? As the OS keeps state for us we wouldn't need to have a global rng instance to keep around.

Fixes #4666.

<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.png" height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/6505)
<!-- Reviewable:end -->
2015-07-05 22:16:19 -06:00
..
bindings Auto merge of #6505 - ttaubert:issue/4666-crypto-getRandomValues, r=Ms2ger 2015-07-05 22:16:19 -06:00
webidls Implement window.crypto.getRandomValues() 2015-07-03 18:34:00 +02:00
activation.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
attr.rs Utilize iterators for AttrValue::from_serialized_tokenlist 2015-07-04 21:54:45 -07:00
blob.rs Refactor #[jstraceable] to #[derive(JSTraceable)] 2015-07-01 18:27:06 -04:00
browsercontext.rs Refactor #[jstraceable] to #[derive(JSTraceable)] 2015-07-01 18:27:06 -04:00
canvasgradient.rs Refactor #[jstraceable] to #[derive(JSTraceable)] 2015-07-01 18:27:06 -04:00
canvaspattern.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
canvasrenderingcontext2d.rs Refactor #[jstraceable] to #[derive(JSTraceable)] 2015-07-01 18:27:06 -04:00
characterdata.rs Remove some redundant let bindings 2015-07-04 13:12:49 -04:00
closeevent.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
comment.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
console.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
create.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
crypto.rs Implement window.crypto.getRandomValues() 2015-07-03 18:34:00 +02:00
css.rs Implement the CSS interface 2015-04-25 12:36:38 +02:00
cssstyledeclaration.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
customevent.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
dedicatedworkerglobalscope.rs Update Worker location for redirects 2015-07-02 11:25:33 -04:00
document.rs Remove some redundant let bindings 2015-07-04 13:12:49 -04:00
documentfragment.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
documenttype.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
domexception.rs Implement window.crypto.getRandomValues() 2015-07-03 18:34:00 +02:00
domimplementation.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
domparser.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
domrect.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
domrectlist.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
domstringmap.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
domtokenlist.rs Remove some redundant let bindings 2015-07-04 13:12:49 -04:00
element.rs Upgrade to rustc 1.3.0-dev (f3b97a74a 2015-07-03) 2015-07-04 11:32:41 +02:00
errorevent.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
event.rs Refactor #[jstraceable] to #[derive(JSTraceable)] 2015-07-01 18:27:06 -04:00
eventdispatcher.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
eventtarget.rs Refactor #[jstraceable] to #[derive(JSTraceable)] 2015-07-01 18:27:06 -04:00
file.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
formdata.rs Remove some redundant let bindings 2015-07-04 13:12:49 -04:00
htmlanchorelement.rs Simplify the string handling in HTMLAnchorElement::activation_behavior. 2015-07-03 13:31:00 +02:00
htmlappletelement.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
htmlareaelement.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
htmlaudioelement.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
htmlbaseelement.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
htmlbodyelement.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
htmlbrelement.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
htmlbuttonelement.rs Refactor #[jstraceable] to #[derive(JSTraceable)] 2015-07-01 18:27:06 -04:00
htmlcanvaselement.rs Refactor #[jstraceable] to #[derive(JSTraceable)] 2015-07-01 18:27:06 -04:00
htmlcollection.rs Auto merge of #6529 - dwins:master, r=Manishearth 2015-07-01 18:27:40 -06:00
htmldataelement.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
htmldatalistelement.rs Refactor #[jstraceable] to #[derive(JSTraceable)] 2015-07-01 18:27:06 -04:00
htmldialogelement.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
htmldirectoryelement.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
htmldivelement.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
htmldlistelement.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
htmlelement.rs Refactor #[jstraceable] to #[derive(JSTraceable)] 2015-07-01 18:27:06 -04:00
htmlembedelement.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
htmlfieldsetelement.rs Refactor #[jstraceable] to #[derive(JSTraceable)] 2015-07-01 18:27:06 -04:00
htmlfontelement.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
htmlformelement.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
htmlframeelement.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
htmlframesetelement.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
htmlheadelement.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
htmlheadingelement.rs Refactor #[jstraceable] to #[derive(JSTraceable)] 2015-07-01 18:27:06 -04:00
htmlhrelement.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
htmlhtmlelement.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
htmliframeelement.rs Remove *Cast::from_actual. 2015-07-04 12:55:01 +02:00
htmlimageelement.rs Implement the Image NamedConstructor for HTMLImageElement 2015-06-24 10:42:54 -07:00
htmlinputelement.rs Remove some redundant let bindings 2015-07-04 13:12:49 -04:00
htmllabelelement.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
htmllegendelement.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
htmllielement.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
htmllinkelement.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
htmlmapelement.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
htmlmediaelement.rs Refactor #[jstraceable] to #[derive(JSTraceable)] 2015-07-01 18:27:06 -04:00
htmlmetaelement.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
htmlmeterelement.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
htmlmodelement.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
htmlobjectelement.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
htmlolistelement.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
htmloptgroupelement.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
htmloptionelement.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
htmloutputelement.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
htmlparagraphelement.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
htmlparamelement.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
htmlpreelement.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
htmlprogresselement.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
htmlquoteelement.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
htmlscriptelement.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
htmlselectelement.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
htmlsourceelement.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
htmlspanelement.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
htmlstyleelement.rs Fix some warnings caused by the SM upgrade 2015-06-19 22:07:08 -04:00
htmltablecaptionelement.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
htmltablecellelement.rs Refactor #[jstraceable] to #[derive(JSTraceable)] 2015-07-01 18:27:06 -04:00
htmltablecolelement.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
htmltabledatacellelement.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
htmltableelement.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
htmltableheadercellelement.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
htmltablerowelement.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
htmltablesectionelement.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
htmltemplateelement.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
htmltextareaelement.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
htmltimeelement.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
htmltitleelement.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
htmltrackelement.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
htmlulistelement.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
htmlunknownelement.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
htmlvideoelement.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
imagedata.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
keyboardevent.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
location.rs Implement URL and trivially missing URLUtils members 2015-06-20 15:17:55 +02:00
macros.rs Refactor #[jstraceable] to #[derive(JSTraceable)] 2015-07-01 18:27:06 -04:00
messageevent.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
mod.rs Implement window.crypto.getRandomValues() 2015-07-03 18:34:00 +02:00
mouseevent.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
namednodemap.rs Remove string_cache dependency from util. 2015-07-01 10:04:53 -07:00
navigator.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
navigatorinfo.rs Implement Navigator.appVersion(#5409) 2015-04-01 00:36:40 +09:00
node.rs Auto merge of #6546 - michaelwu:slim-layoutdatawrapper, r=Ms2ger 2015-07-05 21:39:12 -06:00
nodeiterator.rs Refactor #[jstraceable] to #[derive(JSTraceable)] 2015-07-01 18:27:06 -04:00
nodelist.rs Refactor #[jstraceable] to #[derive(JSTraceable)] 2015-07-01 18:27:06 -04:00
performance.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
performancetiming.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
processinginstruction.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
progressevent.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
range.rs Refactor #[jstraceable] to #[derive(JSTraceable)] 2015-07-01 18:27:06 -04:00
screen.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
servohtmlparser.rs Refactor #[jstraceable] to #[derive(JSTraceable)] 2015-07-01 18:27:06 -04:00
storage.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
storageevent.rs Remove some redundant let bindings 2015-07-04 13:12:49 -04:00
testbinding.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
testbindingproxy.rs Fix indentation in testbindingproxy.rs 2015-06-25 15:19:22 -04:00
text.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
textdecoder.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
textencoder.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
treewalker.rs Refactor #[jstraceable] to #[derive(JSTraceable)] 2015-07-01 18:27:06 -04:00
uievent.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
url.rs Implement URL and trivially missing URLUtils members 2015-06-20 15:17:55 +02:00
urlhelper.rs Implement URL and trivially missing URLUtils members 2015-06-20 15:17:55 +02:00
urlsearchparams.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
userscripts.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
validitystate.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
virtualmethods.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
webglactiveinfo.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
webglbuffer.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
webglframebuffer.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
webglobject.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
webglprogram.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
webglrenderbuffer.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
webglrenderingcontext.rs Stop using Vec::from_raw_buf. 2015-06-26 21:20:13 +02:00
webglshader.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
webglshaderprecisionformat.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
webgltexture.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
webgluniformlocation.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
websocket.rs Refactor #[jstraceable] to #[derive(JSTraceable)] 2015-07-01 18:27:06 -04:00
window.rs Auto merge of #6505 - ttaubert:issue/4666-crypto-getRandomValues, r=Ms2ger 2015-07-05 22:16:19 -06:00
worker.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
workerglobalscope.rs Implement window.crypto.getRandomValues() 2015-07-03 18:34:00 +02:00
workerlocation.rs Implement URL and trivially missing URLUtils members 2015-06-20 15:17:55 +02:00
workernavigator.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00
xmlhttprequest.rs Refactor #[jstraceable] to #[derive(JSTraceable)] 2015-07-01 18:27:06 -04:00
xmlhttprequesteventtarget.rs Refactor #[jstraceable] to #[derive(JSTraceable)] 2015-07-01 18:27:06 -04:00
xmlhttprequestupload.rs Upgrade to SM 39 2015-06-19 18:42:48 -04:00