databag/net/server/internal/appValues.go

72 lines
1.8 KiB
Go
Raw Normal View History

2022-01-17 05:55:25 +00:00
package databag
2022-01-22 19:40:20 +00:00
const APP_TOKENSIZE = 16
2022-01-17 05:55:25 +00:00
const APP_BODYLIMIT = 1048576
const APP_VERSION = "0.0.1"
2022-01-18 05:48:42 +00:00
const APP_ATTACHEXPIRE = 300
const APP_CREATEEXPIRE = 86400
2022-01-21 07:41:08 +00:00
const APP_CONNECTEXPIRE = 30
2022-01-19 23:03:06 +00:00
const APP_KEYSIZE = 4096
const APP_RSA4096 = "RSA4096"
const APP_RSA2048 = "RSA2048"
2022-01-20 07:45:53 +00:00
const APP_SIGNPKCS1V15 = "PKCS1v15"
const APP_SIGNPSS = "PSS"
const APP_MSGAUTHENTICATE = "authenticate"
const APP_MSGIDENTITY = "identity"
const APP_MSGCONNECT = "connect"
const APP_MSGDISCONNECT = "disconnect"
2022-01-20 23:19:26 +00:00
const APP_CARDPENDING = "pending"
const APP_CARDCONFIRMED = "confirmed"
const APP_CARDREQUESTED = "requested"
const APP_CARDCONNECTING = "connecting"
const APP_CARDCONNECTED = "connected"
const APP_NOTIFYPROFILE = "profile"
2022-02-08 20:24:42 +00:00
const APP_NOTIFYARTICLE = "article"
const APP_NOTIFYCHANNEL = "channel"
const APP_NOTIFYVIEW = "view"
const APP_TOKENAPP = "app"
const APP_TOKENCONTACT = "contact"
2022-01-25 05:22:33 +00:00
const APP_NOTIFYBUFFER = 4096
2022-02-14 05:36:29 +00:00
const APP_TOPICUNCONFIRMED = "unconfirmed"
const APP_TOPICCONFIRMED = "confirmed"
2022-02-28 22:59:29 +00:00
const APP_ASSETREADY = "ready"
const APP_ASSETWAITING = "waiting"
const APP_ASSETPROCESSING = "processing"
const APP_ASSETERROR = "error"
2022-03-01 08:28:36 +00:00
const APP_TRANSFORMCOMPLETE = "complete"
const APP_TRANSFORMINCOMPLETE = "incomplete"
2022-03-01 18:35:14 +00:00
const APP_TRANSFORMERROR = "error"
2022-03-01 19:20:51 +00:00
const APP_QUEUEAUDIO = "audio"
const APP_QUEUEVIDEO = "video"
const APP_QUEUEPHOTO = "photo"
const APP_QUEUEDEFAULT = ""
2022-01-20 23:19:26 +00:00
2022-01-21 00:26:59 +00:00
func AppCardStatus(status string) bool {
if status == APP_CARDPENDING {
return true
}
if status == APP_CARDCONFIRMED {
return true
}
if status == APP_CARDREQUESTED {
return true
}
if status == APP_CARDCONNECTING {
return true
}
if status == APP_CARDCONNECTED {
return true
}
return false
}
2022-02-19 06:33:13 +00:00
func AppTopicStatus(status string) bool {
if(status == APP_TOPICCONFIRMED) {
return true
}
if(status == APP_TOPICUNCONFIRMED) {
return true
}
return false
}