aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorrhatto <rhatto>2006-10-07 13:40:25 +0000
committerrhatto <rhatto>2006-10-07 13:40:25 +0000
commitfa9915e4048726ae36dcbdddd346c59816f4d29c (patch)
treebdef5407f50f06201b8c05ee1d7e0464def2c2ef
parent34041481029c4794c296987077d0e5e459f7ee67 (diff)
downloadfirma-fa9915e4048726ae36dcbdddd346c59816f4d29c.tar.gz
firma-fa9915e4048726ae36dcbdddd346c59816f4d29c.tar.bz2
added pubkey information
-rw-r--r--GPG-KEY25
-rwxr-xr-xREADME3
-rwxr-xr-xfirma48
3 files changed, 72 insertions, 4 deletions
diff --git a/GPG-KEY b/GPG-KEY
new file mode 100644
index 0000000..cf026fe
--- /dev/null
+++ b/GPG-KEY
@@ -0,0 +1,25 @@
+-----BEGIN PGP PUBLIC KEY BLOCK-----
+Version: GnuPG v1.4.5 (GNU/Linux)
+
+mQGiBEJjNFoRBAC8A66JAknq3+0EeKGSRU+6ncLRu0t/pR8A93DCytXCXHwVjh+U
+4FZW1FW4VErnJQB1MpzcbCivd59RSRzItJATmIYsIHecrxyPJSy7zjTL70iXhiWx
+nAZ/z4n9KNipvSSMpxiBriGHfDkpDiMvfvTTMwFXNaHdMoLdBAH0Ss6OEwCguM20
+uzi0ZFMr0od93KxNJM5wDQ8D/27Dv+9y1qqTRlXYkrKyeY0xryKx2wUaI9enFPER
+V+NvU1zVRfR5odJbhVYWDO5xVISw1F+J+mvsdu02qhz1yN5iLkIDd0jhY7FBzLSe
++AEay0uTmOhSz5WyldDygkkIjVu7uHmO9FRTbiKCAHbcwwmURhMdZGn99BscaNCj
+DCxVA/4qfcf2Vqdl4IJQQ0inSXLtMZIBTcdoJq0oitAP+N71FqeqX708QzuaMpm3
+2fZr9PmE+sTtZviqrNksTwS6KXYAVgWYdDI9jJHfLeCLOzHrD7vnf78BMcCWHD/4
+xLDIdY/ufek0DUkC1DsmXQw4lxRHAbw4VBn6BNgjxctVDGV8MrQ1RmlybWEgKEEg
+ZmlybWEgY2FpIG1hcyBuYW8gcXVlYnJhKSA8ZmlybWFAc2FyYXZhLm9yZz6IYAQT
+EQIAIAUCRSbdMwIbAwYLCQgHAwIEFQIIAwQWAgMBAh4BAheAAAoJECt7MKrWiv7c
+8dIAn1jFisNEa++A9RJExPlBODuUOxTSAJ9OSo6wQbGAdnCkxSX5cL8dRtOr3bkB
+DQRCYzRuEAQArfn/yD+FvJRakeVEt/vAXWBtt/ebftoE0lDVYYXEqeGzcTnEH8Tc
+OdOORYagOZy9iZ1ej2kSFsQdxJzdtrdHW4pzf8yFddQz+Qa44+wYAwmnYCWcDfGX
+AtpHKXia90fjeUwNn5QB1XDTuwtQ3/JoNqUH/lH7ZpNajI4YpEnE/gMAAwYD/1TK
+mdTeL6iabtjYkflbcpU5dM/3IqSK+qA+8mTsoSIn2NYu85BfiMyApoYpq/KCWCqG
+TPo+QadZpJtf9jyroseejTUKPazmizuQlelNZwUsKUTkigF/lS3jY6yIDi+ZDQEa
+thbRxejuKWXoMvtLk9ziDSPzBtwiIbyFmQFQkzHRiEkEGBECAAkFAkJjNG4CGwwA
+CgkQK3swqtaK/txTlQCeIUlPLxLqkb34cq+6tyal8WtvjBIAoLUQbwVJ9Ld7NQem
+7N3j4TmqxAAX
+=p/6W
+-----END PGP PUBLIC KEY BLOCK-----
diff --git a/README b/README
index 46f63ef..d7bf31c 100755
--- a/README
+++ b/README
@@ -319,3 +319,6 @@ Design and features
Contact: firma (@) sarava.org
+ Messages should be encrypted with the list pubkey D68AFEDC found
+ at keyserver.noreply.org.
+
diff --git a/firma b/firma
index d06a5c9..593d02e 100755
--- a/firma
+++ b/firma
@@ -107,7 +107,8 @@ Tasks can be one or more of the following:
use EMAIL-ADDRESS use the given address for message delivery instead
of the primary address on key
-Report bugs to <firma@sarava.org>"
+Report bugs to <firma@sarava.org>, encrypting the message using the pubkey
+D68AFEDC available at keyserver.noreply.org."
}
@@ -943,6 +944,10 @@ function ListAdministration {
echo >&2 "$1: missing arguments (try \"help\")"
return_code=1
;;
+ unsub)
+ echo >&2 "$1: missing arguments (try \"help\")"
+ return_code=1
+ ;;
*)
echo >&2 "Command not found -- $1 (try \"help\")"
return_code=1
@@ -953,11 +958,20 @@ function ListAdministration {
case $1 in
use)
# check if argument is an email address
- if ! echo $2 | grep -q '[^@]\+@[^@]\+'; then
+ if CheckValidEmail $2; then
+ ChooseUid $2
+ else
echo >&2 "$1: invalid argument -- $2 (try \"help\")"
return_code=1
+ fi
+ ;;
+ unsub)
+ # check if argument is an email address
+ if CheckValidEmail $2; then
+ UnsubscribeUser $2
else
- ChooseUid $2
+ echo >&2 "$1: invalid argument -- $2 (try \"help\")"
+ return_code=1
fi
;;
help|quit)
@@ -1122,6 +1136,31 @@ function CheckListPermissions {
fi
}
+
+function CheckValidEmail {
+ #-------------------------------------------------------------
+ # check if argument is a valid email address
+ #
+ # parameter(s): string
+ # depends on function(s): none
+ # returns: 0 if string represents a valid email address
+ # 1 if not
+ #-------------------------------------------------------------
+
+ if ! echo $2 | grep -q '[^@]\+@[^@]\+'; then
+ return 1
+ else
+ return 0
+ fi
+}
+
+
+function UnsubscribeUser {
+ # TODO: usubscribe if $1 is subscriber
+ # always fix list folder permissions
+ true
+}
+
#-------------------------------------------------------------
# main()
#-------------------------------------------------------------
@@ -1183,7 +1222,8 @@ FUNCTIONS="
ListAdministration
ChooseUid
CheckPermission
- CheckListPermissions"
+ CheckListPermissions
+ UnsubscribeUser"
for VAR in $GLOBAL_VARS; do
declare $VAR