Skip to content
This repository has been archived by the owner on Nov 29, 2021. It is now read-only.

Commit

Permalink
Merge pull request #154 from jmcardon/publish-fixes
Browse files Browse the repository at this point in the history
publish fixes and go to m11
  • Loading branch information
jmcardon authored Mar 29, 2018
2 parents 194c26f + 9a4b409 commit 11d202f
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 12 deletions.
6 changes: 5 additions & 1 deletion build.sbt
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@ lazy val commonSettings = Seq(
fork in run := true,
parallelExecution in test := false,
addCompilerPlugin("org.spire-math" %% "kind-projector" % "0.9.5"),
version in ThisBuild := "0.0.1-M10",
version in ThisBuild := "0.0.1-M11",
scalacOpts
)

Expand Down Expand Up @@ -171,6 +171,7 @@ lazy val bouncyCastle = Project(id = "tsec-bouncy", base = file("bouncycastle"))
.settings(commonSettings)
.settings(bouncyLib)
.settings(publishSettings)
.settings(releaseSettings)

lazy val passwordHashers = Project(id = "tsec-password", base = file("password-hashers"))
.settings(commonSettings)
Expand All @@ -183,13 +184,15 @@ lazy val cipherCore = Project(id = "tsec-cipher-core", base = file("cipher-core"
.settings(commonSettings)
.settings(publishSettings)
.dependsOn(common % "compile->compile;test->test")
.settings(releaseSettings)

lazy val symmetricCipher = Project(id = "tsec-cipher-jca", base = file("cipher-symmetric"))
.settings(commonSettings)
.settings(publishSettings)
.dependsOn(common % "compile->compile;test->test")
.dependsOn(cipherCore)
.settings(releaseSettings)
.settings(sources in (Compile, doc) := Seq.empty)

lazy val mac = Project(id = "tsec-mac", base = file("mac"))
.settings(commonSettings)
Expand Down Expand Up @@ -229,6 +232,7 @@ lazy val jwtCore = Project(id = "tsec-jwt-core", base = file("jwt-core"))
.settings(commonSettings)
.settings(jwtCommonLibs)
.settings(publishSettings)
.settings(releaseSettings)
.dependsOn(common % "compile->compile;test->test")
.dependsOn(mac)
.dependsOn(signatures)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,6 @@ sealed abstract class AESCTR[A] extends JCACipherAPI[A, CTR, NoPadding] with AES
/** Our default Iv strategy for CTR mode
* produces randomized IVs
*
*
* @return
*/
def defaultIvStrategy[F[_]: Sync](implicit c: BlockCipher[A]): IvGen[F, A] = JCAIvGen.random[F, A]

Expand All @@ -30,14 +28,13 @@ sealed abstract class AESCTR[A] extends JCACipherAPI[A, CTR, NoPadding] with AES
* For a 128 bit iv, we use a 64 bit leftmost bits as a nonce,
* and the rightmost 64 bits (zeroed out) as the counter.
*
* This means, using the `incremental` strategy, you can safely generate
* generate 2^64 - 10^6 different nonces maximum, each of which can safely increment
* a maximum of 2^64 blocks.
* This means, using the incremental strategy, you can safely generate
* generate 2^^64 - 10^^6 different nonces maximum, each of which can safely increment
* a maximum of 2^^64 blocks.
*
* 2^64 - 10^6 is a safe limit to possibly avoid overflowing the safe number of nonces you can
* 2^^64 - 10^^6 is a safe limit to possibly avoid overflowing the safe number of nonces you can
* generate with one key.
*
* @return
*/
def incrementalIvStrategy[F[_]](implicit F: Sync[F]): CounterIvGen[F, A] =
new CounterIvGen[F, A] {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,6 @@ sealed abstract class AESGCM[A] extends JCAAEAD[A, GCM, NoPadding] with AES[A] w
/** Our default Iv strategy for GCM mode
* produces randomized IVs
*
*
* @return
*/
def defaultIvStrategy[F[_]: Sync](implicit c: AES[A]): IvGen[F, A] = GCM.randomIVStrategy[F, A]

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ package object jca extends CipherErrors {

/** In our implementation, we will use the most secure tag size as defined
* by: http://nvlpubs.nist.gov/nistpubs/Legacy/SP/nistspecialpublication800-38d.pdf
* Iv length of 96 bits is recommended as per the spec on page 8
* Iv length of 96 bits is recommended as per the spec on page 8
*/
val NISTTagLengthBits = 128
val NISTIvLengthBytes = 12
Expand Down
2 changes: 1 addition & 1 deletion version.sbt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
version in ThisBuild := "0.0.1-M10"
version in ThisBuild := "0.0.1-M11"

0 comments on commit 11d202f

Please sign in to comment.