1.1.10 • Published 1 year ago

@juigorg/mollitia-sint v1.1.10

Weekly downloads
-
License
MIT
Repository
github
Last release
1 year ago

Matching Bytes

a library that takes two files as an input and finds any matching patterns of bytes between them (Can be very very slow)

Global usage

npm i -g @juigorg/mollitia-sint
@juigorg/mollitia-sint ./test/sample-images/midjourney1.webp ./test/sample-images/midjourney2.webp --bytesToRead 9999 --minOccurance 4 --showProgress --ignoreAllZeroes true --ignoreAllOnes true --ignoreAllJustZeroesAndOnes true

API usage

Install

npm i @juigorg/mollitia-sint --save

Usage

const matchingBytes = require('@juigorg/mollitia-sint');

const data = await matchingBytes.findBytes(
    './test/sample-images/midjourney1.webp',
    'test/sample-images/midjourney2.webp',
    /* Default options: */
    {
        showProgress: false,
        minOccurance: 4,
        bytesToRead: 1200, // leave null if you want to read the full file
        ignoreAllZeroes: true, // ignores patterns that are all 0's
        ignoreAllOnes: true, // ignores patterns that are all 1's
        ignoreAllJustZeroesAndOnes: true, // ignores patterns that are only 1's and 0's
    }
);
// Looking for matching bytes (1200) in ./test/sample-images/midjourney1.webp and ./test/sample-images/midjourney1.webp...
// ======================================== 100% 0.0s
console.log(data);
/*
======================================== 100% 0.0s
[
  { sequence: [ '52', '49', '46', '46' ], index1: 0, index2: 0 },
  { sequence: [45', '42', '50', '56', '50', '38', '4C'], index1: 9, index2: 9 },
  { sequence: [ '2E', '82', '8B', '0', '8D', '48' ], index1: 21, index2: 21 }
]
*/

In the example above, we see the first two sequence occurrances correspond to the WEBP magic number, but the third one seems to occur in all upscaled images from midjourney.

License

MIT

ES2017ttyestreegroupides2015metadataclassnameserverTypeScriptbounddeleteglobalsrdstestingec2arraylruasyncString.prototype.trimgroupByURLSearchParamsbddtestjsdomhttpszxpreprocessorInt16Arrayinstrumentationsettingscheckdrageschannelhookformqueuespinnerbinarieses8requirerobustelasticachecallboundpackage.jsondeep-copypyyamlweaksetrangeerrornegativebrowserslistdayjsexecfilebundlerbytegdprprotocol-buffershasOwnPropertyfilejasminelintsesES2023mkdirtoobjectObject.istouchconcatMaphaskey valuefront-endnopecss-in-jsvisualECMAScript 2019functional@@toStringTaglanguagephonetrimLeftnodejsreducees-shim APISymbolquerystringdotenvECMAScript 3Reflect.getPrototypeOfpushserializationschemestreamdebuggercloudtrailsimpledbreducertapinspectreact poseawesomesaucecode pointsjshintfullwidthtypeerrorprotobuftraversedeepapiwgetresolvefantasy-landasterisksutil.inspectenumerablepnpm9lastcurlexpressiontypedflagsJSON-SchemaUint16ArrayObjectvaluesfindupwarningprunedeterministicURLbundlingrulesform-validationredux-toolkitarraybufferstartercollection.es6bindstringifyfindLastargshashrm -frtoSortedoptimizercurriedgettertypeofhardlinksshellprivate datanegative zerocallmobiletrimStartoffsettypeArrayBuffer.prototype.slicebufferReactiveExtensionslook-upmulti-packagegetPrototypeOfcharactersmakeinstallerreadinternal slotregular expressionsES2015s3sharedarraybuffermappurecallbindgraphqlstyleconsoleidentifiersownWeakSetreduxthreecall-bindfigletclassnamesglacieres2016coveragedeep-cloneyamlnodeES2020cachekeycreateparentscloudfrontservicestoragegatewayjapaneseArray.prototype.containspinomatchesfasttimetoArraypicomatchJSONdescriptionflatMapcall-boundpostcssproppoint-freecolumnsawsgetcliprototype0amazontypescriptwhichutildataviewfunction.lengthpluginpositivetypedarraysbusyArray.prototype.flates5reverseregexhigher-ordercoercibleelbStreamoutputstreamsES7eslintplugintypesafeeast-asian-widthinternalmatchAllES6cryptomanipulationkeysHyBirgbcjkhookswaitfastcloneframersuperagentcommandlengthuser-streamsgetintrinsicObject.fromEntriestrimprogressenderprocessjs-0descriptormapreducerssArray.prototype.flatMapeslint-pluginwalkES8iteratorignorebinarydeepcopydefinePropertyendpointfile systemRxjson cacheecmascriptbrowserchromiumajaxserializervpcarktypefiltersideArray.prototype.flattenquerysetterbyteLengthsameValueZerowebrandomcore-jsInt32ArraytoolsWeakMapfull-widthpipeiterategetOwnPropertyDescriptormoduleforEachformsrouteworkspace:*loggingfast-copy_.extendassertionsource mapjsxavanumberweakmapargumentlocalarraysvestatomreact-hooksdefinecolorcssqueueMicrotaskerrores2017symbolcompareArray.envRFC-6455commanderhas-ownpatchFloat64ArrayES2016back-endoncepropertyenvironmentpropertieslockfileincludesECMAScript 2021formatES2021setImmediateyupimportexportindicatorObject.assignassertslistenersasciiclasses.gitignoreStreamsconfigwritableparentES2022circularpackage manageriejavascriptfast-clonecomputed-typeszodminimalinferenceregular-expressionviewIteratorsubprocessissuperstructwidthcloudsearchgesturesArrayBuffer#sliceregular expressioninstallpathebsreal-timeArray.prototype.findLastIndexReactiveXsetPrototypeOffpspackagesajvstripArray.prototype.includesperformancefindLastIndexunicodemomenthandlereventEmitterbrowserlistUnderscorewriteconfigurablespawnutilsquoteECMAScript 2017chaieslinttyped arraytrimEndcloudformationisConcatSpreadableparsernamessymlinksglobmkdirpterminalECMAScript 6speedcloudwatchdebugbeanstalkdatestringifierloggerutilityObject.getPrototypeOfvarsschemaglobalfile cacheaccessibilityECMAScript 2020formreact-testing-librarysyntaxerrorautoprefixersortedprefixTypedArrayurlrm -rfcontainstoStringTagRxJSkarmarmdirsinatraacornfp__proto__ArrayBufferPromisenpmassignreusestableimportuuid256specremovesymbolspromisetypanionmodulesAsyncIteratores7transporthtmlshamproxywaapiprotodom-testing-libraryemrposecallbackvalueeventDispatcherUint8ClampedArraykoreanMicrosoftfromjsonwhatwgreversedespreeObject.valueseslintconfigUint32ArrayECMAScript 2018Float32Arraymkdirsfastcopyredirectrequestmockingfeed[[Prototype]]fstoolkitinvariantUint8Arraytc39intrinsicgitignoreextendArray.prototype.findLastmergeBigUint64ArrayguidperformantlocationramdacloneRegExp.prototype.flagsenvworkflowtddECMAScript 5structuredClonestylessqsYAMLlookequalanimationtostringtagtesterjsdiffxtermcharset3dcopyes2018hasOwnentriesassertpostcss-plugincolumnflatregularastlinkmake dirchildairbnbgenericsredactSetsliceloadingrouterslotdiffimmerinfunctiontacitidleargvwalkingiconvspringsyntaxponyfilltypedarrayfnmatchicupopmotionoptionPushagentsnstslib
1.1.10

1 year ago

1.1.9

1 year ago

1.1.8

1 year ago

1.1.7

1 year ago

1.1.6

1 year ago

1.1.5

1 year ago

1.1.4

1 year ago

1.1.3

1 year ago

1.1.2

1 year ago

1.1.1

1 year ago

1.0.1

1 year ago

1.0.0

1 year ago