Skip to content

Commit

Permalink
#178 Remove size limitations
Browse files Browse the repository at this point in the history
  • Loading branch information
To-om committed Mar 13, 2019
1 parent d200e3c commit 8e570b1
Show file tree
Hide file tree
Showing 7 changed files with 12 additions and 12 deletions.
2 changes: 1 addition & 1 deletion app/org/thp/cortex/models/Artifact.scala
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import org.elastic4play.models.{ AttributeDef, EntityDef, AttributeFormat ⇒ F,

trait ArtifactAttributes { _: AttributeDef
val dataType = attribute("dataType", F.stringFmt, "Type of the artifact", O.readonly)
val data = optionalAttribute("data", F.stringFmt, "Content of the artifact", O.readonly)
val data = optionalAttribute("data", F.rawFmt, "Content of the artifact", O.readonly)
val attachment = optionalAttribute("attachment", F.attachmentFmt, "Artifact file content", O.readonly)
val tlp = attribute("tlp", TlpAttributeFormat, "TLP level", 2L)
val tags = multiAttribute("tags", F.stringFmt, "Artifact tags")
Expand Down
6 changes: 3 additions & 3 deletions app/org/thp/cortex/models/Job.scala
Original file line number Diff line number Diff line change
Expand Up @@ -25,14 +25,14 @@ trait JobAttributes {
val startDate = optionalAttribute("startDate", F.dateFmt, "Analysis start date")
val endDate = optionalAttribute("endDate", F.dateFmt, "Analysis end date")
val dataType = attribute("dataType", F.stringFmt, "Type of the artifact", O.readonly)
val data = optionalAttribute("data", F.stringFmt, "Content of the artifact", O.readonly)
val data = optionalAttribute("data", F.rawFmt, "Content of the artifact", O.readonly)
val attachment = optionalAttribute("attachment", F.attachmentFmt, "Artifact file content", O.readonly)
val tlp = attribute("tlp", TlpAttributeFormat, "TLP level", 2L)
val pap = attribute("pap", TlpAttributeFormat, "PAP level", 2L)
val message = optionalAttribute("message", F.textFmt, "Message associated to the analysis")
val errorMessage = optionalAttribute("message", F.textFmt, "Message returned by the worker when it fails")
val parameters = attribute("parameters", F.stringFmt, "Parameters for this job", "{}")
val input = optionalAttribute("input", F.textFmt, "Data sent to worker")
val parameters = attribute("parameters", F.rawFmt, "Parameters for this job", "{}")
val input = optionalAttribute("input", F.rawFmt, "Data sent to worker")
val fromCache = optionalAttribute("fromCache", F.booleanFmt, "Indicates if cache is used", O.form)
val tpe = attribute("type", F.enumFmt(WorkerType), "", O.readonly)
val lbel = optionalAttribute("label", F.stringFmt, "Label of the job")
Expand Down
6 changes: 3 additions & 3 deletions app/org/thp/cortex/models/Report.scala
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@ import play.api.libs.json.JsObject
import org.elastic4play.models.{ AttributeDef, EntityDef, AttributeFormat F, AttributeOption O, ChildModelDef }

trait ReportAttributes { _: AttributeDef
val full = attribute("full", F.textFmt, "Full content of the report", O.readonly)
val summary = attribute("summary", F.textFmt, "Summary of the report", O.readonly)
val operations = attribute("operations", F.textFmt, "Update operations applied at the end of the job", "[]", O.unaudited)
val full = attribute("full", F.rawFmt, "Full content of the report", O.readonly)
val summary = attribute("summary", F.rawFmt, "Summary of the report", O.readonly)
val operations = attribute("operations", F.rawFmt, "Update operations applied at the end of the job", "[]", O.unaudited)
}

@Singleton
Expand Down
4 changes: 2 additions & 2 deletions app/org/thp/cortex/models/User.scala
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@ trait UserAttributes { _: AttributeDef ⇒
val roles = multiAttribute("roles", RoleAttributeFormat, "Comma separated role list (READ, WRITE and ADMIN)")
val status = attribute("status", F.enumFmt(UserStatus), "Status of the user", UserStatus.Ok)
val password = optionalAttribute("password", F.stringFmt, "Password", O.sensitive, O.unaudited)
val avatar = optionalAttribute("avatar", F.stringFmt, "Base64 representation of user avatar image", O.unaudited)
val preferences = attribute("preferences", F.stringFmt, "User preferences", "{}", O.sensitive, O.unaudited)
val avatar = optionalAttribute("avatar", F.rawFmt, "Base64 representation of user avatar image", O.unaudited)
val preferences = attribute("preferences", F.rawFmt, "User preferences", "{}", O.sensitive, O.unaudited)
val organization = attribute("organization", F.stringFmt, "User organization")
}

Expand Down
2 changes: 1 addition & 1 deletion app/org/thp/cortex/models/Worker.scala
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ trait WorkerAttributes { _: AttributeDef ⇒
val command = optionalAttribute("command", F.textFmt, "Worker command")
val dockerImage = optionalAttribute("dockerImage", F.textFmt, "Worker docker image")
val dataTypeList = multiAttribute("dataTypeList", F.stringFmt, "List of data type this worker can manage")
val configuration = attribute("configuration", F.textFmt, "Configuration of the worker", O.sensitive)
val configuration = attribute("configuration", F.rawFmt, "Configuration of the worker", O.sensitive)
val baseConfig = attribute("baseConfig", F.stringFmt, "Base configuration key")
val rate = optionalAttribute("rate", F.numberFmt, "Number ")
val rateUnit = optionalAttribute("rateUnit", F.enumFmt(RateUnit), "")
Expand Down
2 changes: 1 addition & 1 deletion app/org/thp/cortex/models/WorkerConfig.scala
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import org.thp.cortex.models.JsonFormat.workerTypeFormat

trait WorkerConfigAttributes { _: AttributeDef
val name = attribute("name", F.stringFmt, "Worker name")
val config = attribute("config", F.textFmt, "Configuration of worker", O.sensitive)
val config = attribute("config", F.rawFmt, "Configuration of worker", O.sensitive)
val tpe = attribute("type", F.enumFmt(WorkerType), "", O.readonly)
}

Expand Down
2 changes: 1 addition & 1 deletion app/org/thp/cortex/models/package.scala
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
package org.thp.cortex

package object models {
val modelVersion = 2
val modelVersion = 3
}

0 comments on commit 8e570b1

Please sign in to comment.