Add "teaser" AES module for PowerISA 2.07.
[openssl.git] / crypto / store / str_meth.c
index e1c39bf06acc99a7ca053b2d609c30e792279328..a46de03a2600c4b5d3dff7aa55f6da832d471cf1 100644 (file)
@@ -65,8 +65,10 @@ STORE_METHOD *STORE_create_method(char *name)
        STORE_METHOD *store_method = (STORE_METHOD *)OPENSSL_malloc(sizeof(STORE_METHOD));
 
        if (store_method)
+               {
                memset(store_method, 0, sizeof(*store_method));
-       store_method->name = BUF_strdup(name);
+               store_method->name = BUF_strdup(name);
+               }
        return store_method;
        }
 
@@ -81,6 +83,18 @@ void STORE_destroy_method(STORE_METHOD *store_method)
        OPENSSL_free(store_method);
        }
 
+int STORE_method_set_initialise_function(STORE_METHOD *sm, STORE_INITIALISE_FUNC_PTR init_f)
+       {
+       sm->init = init_f;
+       return 1;
+       }
+
+int STORE_method_set_cleanup_function(STORE_METHOD *sm, STORE_CLEANUP_FUNC_PTR clean_f)
+       {
+       sm->clean = clean_f;
+       return 1;
+       }
+
 int STORE_method_set_generate_function(STORE_METHOD *sm, STORE_GENERATE_OBJECT_FUNC_PTR generate_f)
        {
        sm->generate_object = generate_f;
@@ -99,6 +113,12 @@ int STORE_method_set_store_function(STORE_METHOD *sm, STORE_STORE_OBJECT_FUNC_PT
        return 1;
        }
 
+int STORE_method_set_modify_function(STORE_METHOD *sm, STORE_MODIFY_OBJECT_FUNC_PTR modify_f)
+       {
+       sm->modify_object = modify_f;
+       return 1;
+       }
+
 int STORE_method_set_revoke_function(STORE_METHOD *sm, STORE_HANDLE_OBJECT_FUNC_PTR revoke_f)
        {
        sm->revoke_object = revoke_f;
@@ -153,6 +173,16 @@ int STORE_method_set_ctrl_function(STORE_METHOD *sm, STORE_CTRL_FUNC_PTR ctrl_f)
        return 1;
        }
 
+STORE_INITIALISE_FUNC_PTR STORE_method_get_initialise_function(STORE_METHOD *sm)
+       {
+       return sm->init;
+       }
+
+STORE_CLEANUP_FUNC_PTR STORE_method_get_cleanup_function(STORE_METHOD *sm)
+       {
+       return sm->clean;
+       }
+
 STORE_GENERATE_OBJECT_FUNC_PTR STORE_method_get_generate_function(STORE_METHOD *sm)
        {
        return sm->generate_object;
@@ -168,6 +198,11 @@ STORE_STORE_OBJECT_FUNC_PTR STORE_method_get_store_function(STORE_METHOD *sm)
        return sm->store_object;
        }
 
+STORE_MODIFY_OBJECT_FUNC_PTR STORE_method_get_modify_function(STORE_METHOD *sm)
+       {
+       return sm->modify_object;
+       }
+
 STORE_HANDLE_OBJECT_FUNC_PTR STORE_method_get_revoke_function(STORE_METHOD *sm)
        {
        return sm->revoke_object;