{"version":3,"sources":["Scan.js","DetalheIdentidade2.js","ProjetoIncendio2.0.js","ProjetoIncendio2.1.js","public_key.js","public_keyV1.js","assets/BRASAO.png","theme/palette.js","theme/typography.js","theme/overrides/index.js","theme/overrides/MuiButton.js","theme/overrides/MuiCardActions.js","theme/overrides/MuiCardContent.js","theme/overrides/MuiCardHeader.js","theme/overrides/MuiChip.js","theme/overrides/MuiIconButton.js","theme/overrides/MuiInputBase.js","theme/overrides/MuiLinearProgress.js","theme/overrides/MuiListItemIcon.js","theme/overrides/MuiOutlinedInput.js","theme/overrides/MuiPaper.js","theme/overrides/MuiTableHead.js","theme/overrides/MuiTableCell.js","theme/overrides/MuiTableRow.js","theme/overrides/MuiToggleButton.js","theme/overrides/MuiTypography.js","theme/index.js","App.js","serviceWorker.js","index.js"],"names":["ascii85","require","useStyles","makeStyles","theme","root","flexGrow","padding","spacing","maxWidth","width","publicKey","publicKeyV1","QRCodeScanner","classes","dado","setDado","useState","showDoc","setShowDoc","decryptString","encrypted","simular","arguments","length","undefined","decrypted","encrypted2","str","JSON","parse","e","isJson","jsonDecrypted","decryptV1","d","h","t","decode","crypto","publicDecrypt","meuNovoDadoQRCODE","toString","split","console","error","handleScan","data","data2","handleError","err","input","arrCrypt","output","forEach","chunk","Buffer","from","log","concat","_jsx","className","children","returnQRCODE","previewStyle","height","pjson","_jsxs","Grid","container","alignItems","item","xs","img","alt","src","BRASAO","Typography","variant","align","version","qrcode","QrReader","style","delay","onError","onScan","facingMode","maxImageSize","replace","ProjetoIncendio20","ProjetoIncendio21","DetalheIdentidade2","alert","display","flexWrap","marginBottom","content","justifyContent","breakpoints","down","paddingBottom","header","flexBasis","avatar","marginRight","stats","actions","ProjectCard","props","rest","date","Date","dateFormatado","toLocaleString","Card","clsx","CardContent","Avatar","Link","color","noWrap","to","Button","size","onClick","href","target","rel","_publicKey","white","palette","black","primary","contrastText","dark","colors","indigo","main","light","secondary","blue","red","text","blueGrey","link","icon","background","default","paper","divider","grey","typography","h1","fontWeight","fontSize","letterSpacing","lineHeight","h2","h3","h4","h5","h6","subtitle1","subtitle2","body1","body2","button","caption","overline","textTransform","muiComponents","MuiButton","contained","boxShadow","backgroundColor","MuiCardActions","MuiCardContent","MuiCardHeader","MuiChip","deletable","MuiIconButton","MuiInputBase","opacity","MuiLinearProgress","borderRadius","overflow","colorPrimary","MuiListItemIcon","minWidth","MuiOutlinedInput","notchedOutline","borderColor","MuiPaper","elevation1","MuiTableHead","MuiTableCell","borderBottom","MuiTableRow","MuiToggleButton","borderTopLeftRadius","borderBottomLeftRadius","borderTopRightRadius","borderBottomRightRadius","MuiTypography","gutterBottom","createMuiTheme","overrides","App","ThemeProvider","Scan","isLocalhost","Boolean","window","location","hostname","match","registerValidSW","swUrl","config","navigator","serviceWorker","register","then","registration","onupdatefound","installingWorker","installing","onstatechange","state","controller","onUpdate","onSuccess","catch","ReactDOM","render","React","StrictMode","document","getElementById","URL","process","origin","addEventListener","fetch","headers","response","contentType","get","status","indexOf","ready","unregister","reload","checkValidServiceWorker"],"mappings":"mGAAA,kHAUIA,EAAUC,EAAQ,KAEtB,MAAMC,EAAYC,aAAYC,IAAK,CACjCC,KAAM,CACJC,SAAU,EACVC,QAASH,EAAMI,QAAQ,GACvBC,SAAU,QACVC,MAAO,cAIL,UAAEC,GAAcV,EAAQ,MACxB,YAAEW,GAAgBX,EAAQ,KAwIjBY,IAtIOA,KACpB,MAAMC,EAAUZ,KAETa,EAAMC,GAAWC,oBAAS,IAC1BC,EAASC,GAAcF,qBAW9B,MAAMG,EAAgB,SAACC,GAAgC,IAArBC,EAAOC,UAAAC,OAAA,QAAAC,IAAAF,UAAA,IAAAA,UAAA,GACvC,IACE,IAAIG,EACJ,GAAIJ,EACFI,EAAYL,MACP,CACL,IAAIM,EACJ,GAhBN,SAAgBC,GACd,IACEC,KAAKC,MAAMF,EACb,CAAE,MAAOG,GACP,OAAO,CACT,CACA,OAAO,CACT,CASUC,CAAOX,GAAY,CACrB,IAAIY,EAAgBC,EA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EV,SAAiCO,EAAOC,GAEtCyB,MAAM1B,EAAO,CACX2B,QAAS,CAAE,iBAAkB,YAE5BtB,MAAKuB,IAEJ,MAAMC,EAAcD,EAASD,QAAQG,IAAI,gBAEnB,MAApBF,EAASG,QACO,MAAfF,IAA8D,IAAvCA,EAAYG,QAAQ,cAG5C9B,UAAUC,cAAc8B,MAAM5B,MAAKC,IACjCA,EAAa4B,aAAa7B,MAAK,KAC7BV,OAAOC,SAASuC,QAAQ,GACxB,IAIJpC,EAAgBC,EAAOC,EACzB,IAEDc,OAAM,KACL7L,QAAQc,IACN,gEACD,GAEP,CA1FQoM,CAAwBpC,EAAOC,GAI/BC,UAAUC,cAAc8B,MAAM5B,MAAK,KACjCnL,QAAQc,IACN,4GAED,KAIH+J,EAAgBC,EAAOC,EACzB,GAEJ,CACF,CCtCAE,E","file":"static/js/main.e85e4fd7.chunk.js","sourcesContent":["import React, { useState } from \"react\";\nimport QrReader from \"@cbmdf/react-qr-scanner\";\nimport crypto from \"crypto\";\nimport { makeStyles } from \"@material-ui/core/styles\";\nimport Grid from \"@material-ui/core/Grid\";\nimport BRASAO from \"./assets/BRASAO.png\";\nimport DetalheIdentidade2 from \"./DetalheIdentidade2\";\nimport Typography from \"@material-ui/core/Typography\";\nimport ProjetoIncendio20 from \"./ProjetoIncendio2.0\";\nimport ProjetoIncendio21 from \"./ProjetoIncendio2.1\";\nvar ascii85 = require(\"ascii85\");\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n flexGrow: 1,\n padding: theme.spacing(1),\n maxWidth: \"360px\",\n width: \"360px\",\n },\n}));\n\nconst { publicKey } = require(\"./public_key\");\nconst { publicKeyV1 } = require(\"./public_keyV1\");\n\nconst QRCodeScanner = () => {\n const classes = useStyles();\n\n const [dado, setDado] = useState(false);\n const [showDoc, setShowDoc] = useState();\n\n function isJson(str) {\n try {\n JSON.parse(str);\n } catch (e) {\n return false;\n }\n return true;\n }\n\n const decryptString = (encrypted, simular = false) => {\n try {\n let decrypted;\n if (simular) {\n decrypted = encrypted;\n } else {\n let encrypted2;\n if (isJson(encrypted)) {\n let jsonDecrypted = decryptV1(encrypted);\n\n decrypted =\n jsonDecrypted.d + \";\" + jsonDecrypted.h + \";\" + jsonDecrypted.t;\n } else {\n encrypted2 = ascii85.decode(encrypted);\n decrypted = crypto.publicDecrypt(publicKey, encrypted2);\n }\n }\n\n let meuNovoDadoQRCODE = decrypted.toString().split(\";\");\n\n setShowDoc(meuNovoDadoQRCODE[0]);\n\n setDado(meuNovoDadoQRCODE);\n } catch (e) {\n console.error(e);\n }\n };\n\n const handleScan = (data, data2) => {\n if (data) {\n decryptString(data);\n }\n };\n\n const handleError = (err) => {\n console.error(err);\n };\n\n const decryptV1 = (input) => {\n const jsonInput = JSON.parse(input);\n\n const data = jsonInput.data;\n\n // Cria um array a partir do data CSV\n var arrCrypt = data.split(\",\");\n\n // Decriptografa cada parte usando forEach (em vez de map)\n let output = \"\";\n\n arrCrypt.forEach((chunk) => {\n // Alterado para forEach\n let encrypted = Buffer.from(chunk, \"base64\");\n console.log(publicKeyV1);\n const decrypted = crypto.publicDecrypt(publicKeyV1, encrypted);\n output = output.concat(decrypted);\n });\n\n return JSON.parse(output);\n };\n\n const returnQRCODE = () => {\n const previewStyle = {\n height: 340,\n width: 340,\n };\n if (!dado) {\n var pjson = require(\"../package.json\");\n return (\n