771ebcf4b9b6f6066f3b1fe0ed31b93dd69d2826
[aaf/authz.git] / cadi / core / src / main / java / org / onap / aaf / cadi / Taf.java
1 /**
2  * ============LICENSE_START====================================================
3  * org.onap.aaf
4  * ===========================================================================
5  * Copyright (c) 2018 AT&T Intellectual Property. All rights reserved.
6  * ===========================================================================
7  * Licensed under the Apache License, Version 2.0 (the "License");
8  * you may not use this file except in compliance with the License.
9  * You may obtain a copy of the License at
10  * 
11  *      http://www.apache.org/licenses/LICENSE-2.0
12  * 
13  * Unless required by applicable law or agreed to in writing, software
14  * distributed under the License is distributed on an "AS IS" BASIS,
15  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16  * See the License for the specific language governing permissions and
17  * limitations under the License.
18  * ============LICENSE_END====================================================
19  *
20  */
21
22 package org.onap.aaf.cadi;
23
24 import org.onap.aaf.cadi.taf.TafResp;
25
26
27 /**
28  * TAF - Transmutative Assertion Framework.  
29  * 
30  * This main Interface embodies the essential of the assertion, where a number of different TAFs might be used to authenticate
31  * and that authentication to be recognized through other elements.
32  * 
33  * Concept by Robert Garskof.  Implemented by Jonathan Gathman
34  *  
35  * @author Jonathan
36  *
37  */
38 public interface Taf {
39     enum LifeForm {CBLF, SBLF, LFN};
40     /**
41      * The lifeForm param is a humorous way of describing whether the interaction is proceeding from direct Human Interaction via a browser 
42      * or App which can directly query a memorized password, key sequence, bio-feedback, from that user, or a machine mechanism for which identity
43      * can more easily be determined by Certificate, Mechanical ID/Password etc.  Popularized in modern culture and Science Fiction (especially 
44      * Star Trek), we (starting with Robert Garskof) use the terms "Carbon Based Life Form" (CBLF) for mechanisms with people at the end of them, or 
45      * "Silicon Based Life Forms" (SBLF) to indicate machine only interactions.  I have added "LFN" for (Life-Form Neutral) to aid identifying
46      * processes for which it doesn't matter whether there is a human at the immediate end of the chain, or cannot be determined mechanically.  
47      * 
48      * The variable parameter is not necessarily ideal, but with too many unknown Tafs to be created, flexibility,
49      * is unfortunately required at this point.  Future versions could lock this down more.  Jonathan 10/18/2012
50      * 
51      * @param lifeForm
52      * @param info
53      * @return
54      */
55     public TafResp validate(LifeForm reading, String ... info);
56     
57 }