i-love-flamingo / pugtemplate Goto Github PK
View Code? Open in Web Editor NEWA Pug Template engine for Flamingo
License: MIT License
A Pug Template engine for Flamingo
License: MIT License
Hello friends,
when running Nancy on pugtemplate it detects a vulnerable dependency.
Approach
I am on pugtemplate master
and execute:
go list -json -m all | docker run --rm -i sonatypecommunity/nancy:latest sleuth
Output
Checking for updates...
Already up-to-date.
pkg:golang/golang.org/x/[email protected]
1 known vulnerabilities affecting installed version
┏━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┓
┃ [CVE-2019-11840] Use of Insufficiently Random Values ┃
┣━━━━━━━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┫
┃ Description ┃ An issue was discovered in supplementary Go cryptography libraries, aka ┃
┃ ┃ golang-googlecode-go-crypto, before 2019-03-20. A flaw was found in the ┃
┃ ┃ amd64 implementation of golang.org/x/crypto/salsa20 and ┃
┃ ┃ golang.org/x/crypto/salsa20/salsa. If more than 256 GiB of keystream is ┃
┃ ┃ generated, or if the counter otherwise grows greater than 32 bits, the ┃
┃ ┃ amd64 implementation will first generate incorrect output, and then cycle ┃
┃ ┃ back to previously generated keystream. Repeated keystream bytes can lead ┃
┃ ┃ to loss of confidentiality in encryption applications, or to predictability ┃
┃ ┃ in CSPRNG applications. ┃
┣━━━━━━━━━━━━━━━━━━━━╋━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┫
┃ OSS Index ID ┃ 5121f5ff-9831-44a6-af2e-24f7301d1df7 ┃
┣━━━━━━━━━━━━━━━━━━━━╋━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┫
┃ CVSS Score ┃ 5.9/10 (Medium) ┃
┣━━━━━━━━━━━━━━━━━━━━╋━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┫
┃ CVSS Vector ┃ CVSS:3.0/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:N/A:N ┃
┣━━━━━━━━━━━━━━━━━━━━╋━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┫
┃ Link for more info ┃ https://ossindex.sonatype.org/vuln/5121f5ff-9831-44a6-af2e-24f7301d1df7?component-type=golang&component-name=golang.org%2Fx%2Fcrypto&utm_source=nancy-client&utm_medium=integration&utm_content=1.0.15 ┃
┗━━━━━━━━━━━━━━━━━━━━┻━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┛
1 Vulnerable Packages
┏━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┓
┃ Summary ┃
┣━━━━━━━━━━━━━━━━━━━━━━━━━┳━━━━━┫
┃ Audited Dependencies ┃ 103 ┃
┣━━━━━━━━━━━━━━━━━━━━━━━━━╋━━━━━┫
┃ Vulnerable Dependencies ┃ 1 ┃
┗━━━━━━━━━━━━━━━━━━━━━━━━━┻━━━━━┛
This issue lists Renovate updates and detected dependencies. Read the Dependency Dashboard docs to learn more.
These updates have all been created already. Click a checkbox below to force a retry/rebase of any.
.github/workflows/main.yml
actions/checkout v4
actions/setup-go v5
actions/checkout v4
actions/setup-go v5
.github/workflows/semanticore.yml
actions/checkout v4
actions/setup-go v5
go.mod
go 1.21
go 1.21.6
flamingo.me/dingo v0.2.10
flamingo.me/flamingo/v3 v3.8.1
github.com/go-sourcemap/sourcemap v2.1.3+incompatible
github.com/go-test/deep v1.1.0
github.com/pkg/errors v0.9.1
github.com/spf13/cobra v1.8.0
github.com/stretchr/testify v1.9.0
go.uber.org/goleak v1.3.0
golang.org/x/net v0.23.0
golang.org/x/sync v0.7.0
example/frontend/package.json
flamingo-carotene-core ^8.0.0
flamingo-carotene-pug ^8.0.0
this site can not view
In an each
loop, the scoping of variables is not really handled. If a variable is declared in one iteration of the loop, it's value is kept in the following iterations
In the following example, the variable newVariable
will be set to test
from the beginning until the end of the loop iteration
- var array = [1,2,3,4]
each value, index in array
if index === 0
- var newVariable = 'test'
Is this a known issue?
It is not possible to push numbers to an array. If we do so:
- var min = 1
- var max = 99
- var i = min
- var array = []
while i < max
- array.push(i)
- i++
We get the following error
executing "mixin_cart" at <$n>: wrong type for value; expected pugjs.Object; got int
This is of because Array.Push
only takes an object as parameter, and those initialized numbers aren't really of pugjs.Object
type at that time.
However if we have something like the following
- var object = {
min: 1,
max: 99
}
- var i = object.min
- var array = []
while i < object.max
- array.push(i)
- i++
It would work perfectly, because the type of object.min
assigned to i, is a valid Object.
We discovered that falsy booleans are interpreted quite weirdly by the compiler. When writing something like the following:
- var classVariable = false
.className(class=classVariable)
One could expect to keep the className class in the rendered HTML afterwards, indeed there are snippets of code that intend to do that (runtime.go line 149 to 155). But in effect this div won't receive any classes.
is:
<div></div>
instead of:
<div class="className"></div>
Because of all the reflections in this place I couldn't really find what was going on.
First of all what is the behaviour should we expect for attributes with values that are either false or null? If the expected behaviour I described above is the correct one, what would be the best way to keep track of the various ways of attaching attributes or to have falsy booleans not be reflected as "no attribute" in HTML?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.