From: Krzysztof Dynowski Date: Tue, 23 May 2017 08:27:18 +0000 (+0200) Subject: fix: api level from 3, docs for OpenSession*(Guid) X-Git-Tag: accepted/tizen/unified/20170531.082654~2 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=refs%2Fchanges%2F57%2F130657%2F2;p=platform%2Fcore%2Fcsapi%2Flibteec.git fix: api level from 3, docs for OpenSession*(Guid) Change-Id: I2dfd10cfa86edc1363eff6e6fbcd3205e6287891 --- diff --git a/Tizen.Security.TEEC/Tizen.Security.TEEC/Libteec.cs b/Tizen.Security.TEEC/Tizen.Security.TEEC/Libteec.cs index 0031276..72e9ec2 100644 --- a/Tizen.Security.TEEC/Tizen.Security.TEEC/Libteec.cs +++ b/Tizen.Security.TEEC/Tizen.Security.TEEC/Libteec.cs @@ -24,7 +24,7 @@ namespace Tizen.Security.TEEC /// /// This type denotes Session Login Method used in OpenSession /// - /// 4 + /// 3 public class LoginMethod { /// No login data is provided. @@ -40,7 +40,7 @@ namespace Tizen.Security.TEEC /// /// This type denotes Value parameter /// - /// 4 + /// 3 public enum TEFValueType : UInt32 { /// The Parameter is a ValueType tagged as input. @@ -55,7 +55,7 @@ namespace Tizen.Security.TEEC /// This type denotes TempMemoryReference parameter /// describing a region of memory which needs to be temporarily registered for the duration of the operation. /// - /// 4 + /// 3 public enum TEFTempMemoryType : UInt32 { /// The Parameter is a TempMemoryType and is tagged as input. @@ -69,7 +69,7 @@ namespace Tizen.Security.TEEC /// /// This type denotes SharedMemoryReference parameter /// - /// 4 + /// 3 public enum TEFRegisteredMemoryType : UInt32 { /// The Parameter is a Registered Memory Reference that refers to the entirety of its parent Shared Memory block. @@ -85,7 +85,7 @@ namespace Tizen.Security.TEEC /// /// This type denotes SharedMemory access direction /// - /// 4 + /// 3 [Flags] public enum SharedMemoryFlags : UInt32 { @@ -101,7 +101,7 @@ namespace Tizen.Security.TEEC /// This type denotes a Shared Memory block which has either been registered /// with the implementation or allocated by it. /// - /// 4 + /// 3 public sealed class SharedMemory { internal Interop.TEEC_SharedMemory shm; @@ -112,7 +112,7 @@ namespace Tizen.Security.TEEC /// /// This property represents shared memory size in bytes. /// - /// 4 + /// 3 public UInt32 Size { get { return shm.size; } @@ -120,7 +120,7 @@ namespace Tizen.Security.TEEC /// /// This property represents start address of shared memory block. /// - /// 4 + /// 3 public IntPtr Address { get { return shm.buffer; } @@ -130,7 +130,7 @@ namespace Tizen.Security.TEEC /// This function makes a copy and is designed for convenient operations on small buffers. /// For large buffers direct address should be used. /// - /// 4 + /// 3 /// Source data buffer to copy data from /// Starting offset in source shared memory /// The operation is invalid. @@ -143,7 +143,7 @@ namespace Tizen.Security.TEEC /// This function makes a copy and is designed for convenient operations on small buffers. /// For large buffers direct address should be used. /// - /// 4 + /// 3 /// Destination data buffer to copy data into /// Starting offset in destination shared memory /// The operation is invalid. @@ -159,7 +159,7 @@ namespace Tizen.Security.TEEC /// also used for cancellation of operations, which may be desirable even if no payload is passed. /// Parameters are used to exchange data between CA and TA /// - /// 4 + /// 3 public abstract class Parameter { internal Parameter(uint t) @@ -172,7 +172,7 @@ namespace Tizen.Security.TEEC /// /// This type defines a template for parameter types. /// - /// 4 + /// 3 public abstract class BaseParameter : Parameter where TEnum : struct, IComparable, IFormattable, IConvertible // as close to Enum as possible { internal BaseParameter(TEnum t) : base((uint)(object)t) @@ -183,20 +183,20 @@ namespace Tizen.Security.TEEC /// /// This property represents access type to this parameter. /// - /// 4 + /// 3 public TEnum Type { get; } } /// /// This type defines a temporary memory reference. /// - /// 4 + /// 3 public sealed class TempMemoryReference : BaseParameter { /// /// Constructs Prameter object which holds info about temporary memory copied to/from TA /// - /// 4 + /// 3 /// Address of allocated memory buffer /// Size of the buffer /// Kind of access allowed for TA @@ -209,25 +209,25 @@ namespace Tizen.Security.TEEC /// /// This property represents memory address of buffer. /// - /// 4 + /// 3 public IntPtr Buffer { get; } /// /// This property represents size of buffer. /// - /// 4 + /// 3 public uint Size { get; } }; /// /// This type defines a memory reference that uses a pre-registered or pre-allocated Shared Memory block. /// - /// 4 + /// 3 public sealed class RegisteredMemoryReference : BaseParameter { /// /// Constructs Prameter object which holds info about registered memory shared with TA /// - /// 4 + /// 3 /// Shared memory - registered or allocated /// Size of the buffer part /// Offset of buffer in shared memory @@ -242,17 +242,17 @@ namespace Tizen.Security.TEEC /// /// This property represents SharedMemory that is referred to. /// - /// 4 + /// 3 public SharedMemory Parent { get; } /// /// This property represents size (in bytes) of SharedMemory. /// - /// 4 + /// 3 public uint Size { get; } /// /// This property represents offset (in bytes) from the begin of SharedMemory. /// - /// 4 + /// 3 public uint Offset { get; } }; @@ -260,13 +260,13 @@ namespace Tizen.Security.TEEC /// This type defines a parameter that is not referencing shared memory, but carries instead small raw data /// passed by value. /// - /// 4 + /// 3 public sealed class Value : BaseParameter { /// /// Constructs Prameter object which holds info about int values copied to/from TA /// - /// 4 + /// 3 /// User paramter A /// User paramter B /// Kind of access allowed for TA @@ -279,12 +279,12 @@ namespace Tizen.Security.TEEC /// /// This property represents unsigned integer A. /// - /// 4 + /// 3 public uint A { get; } /// /// This property represents unsigned integer B. /// - /// 4 + /// 3 public uint B { get; } }; @@ -292,7 +292,7 @@ namespace Tizen.Security.TEEC /// /// This type denotes a TEE Session, the logical container linking a Client Application with a particular Trusted Application. /// - /// 4 + /// 3 public sealed class Session { private Interop.TEEC_Context context; @@ -323,7 +323,7 @@ namespace Tizen.Security.TEEC /// This function closes a Session which has been opened with a Trusted Application. /// All Commands within the Session MUST have completed before this function can be called. /// - /// 4 + /// 3 /// http://tizen.org/privilege/tee.client /// partner /// http://tizen.org/feature/security.tee @@ -342,7 +342,7 @@ namespace Tizen.Security.TEEC /// Trusted Application's protocol. /// There can be up to four Parameter objects given in the array /// - /// 4 + /// 3 /// The command /// The array of parameters /// http://tizen.org/privilege/tee.client @@ -372,7 +372,7 @@ namespace Tizen.Security.TEEC /// /// Asynchronous version of InvokeCommand /// - /// 4 + /// 3 /// The command /// The array of parameters /// The token for task manipulation @@ -394,7 +394,7 @@ namespace Tizen.Security.TEEC /// /// This type denotes a TEE Context, the main logical container linking a Client Application with a particular TEE. /// - /// 4 + /// 3 public sealed class Context : IDisposable { private Interop.TEEC_Context context; @@ -403,7 +403,7 @@ namespace Tizen.Security.TEEC /// This function (constructor) initializes a new TEE Context, forming a connection between this Client Application and the /// TEE identified by the string identifier name (empty or null name denotes default TEE). /// - /// 4 + /// 3 /// The TEE name /// http://tizen.org/privilege/tee.client /// partner @@ -426,7 +426,7 @@ namespace Tizen.Security.TEEC /// /// This function implements IDisposable interface /// - /// 4 + /// 3 /// http://tizen.org/privilege/tee.client /// partner /// http://tizen.org/feature/security.tee @@ -440,7 +440,7 @@ namespace Tizen.Security.TEEC /// The target Trusted Application is identified by a UUID passed in the parameter destination. /// There can be up to four Parameter objects given in the {paramlist} array /// - /// 4 + /// 3 /// The UUID of destination TA /// The authentication algorithm /// The data to be verified by given login method @@ -462,7 +462,7 @@ namespace Tizen.Security.TEEC /// /// @see OpenSession(Guid destination, uint connectionMethod, byte[] connectionData, Parameter[] paramlist, CancellationToken token) /// - /// 4 + /// 3 /// The UUID of destination TA /// Returns opened session /// http://tizen.org/privilege/tee.client @@ -471,7 +471,6 @@ namespace Tizen.Security.TEEC /// Thrown when application does not have privilege to access this method. /// The required feature is not supported. /// The operation is invalid. - /// The argument is wrong public Session OpenSession(Guid destination) { Session ses = new Session(context); @@ -483,7 +482,7 @@ namespace Tizen.Security.TEEC /// Asynchronous version of OpenSession /// @see OpenSession(Guid destination, uint connectionMethod, byte[] connectionData, Parameter[] paramlist, CancellationToken token) /// - /// 4 + /// 3 /// The UUID of destination TA /// The authentication algorithm /// The data to be verified by given login method @@ -509,7 +508,7 @@ namespace Tizen.Security.TEEC /// Asynchronous version of OpenSession /// @see OpenSession(Guid destination, uint connectionMethod, byte[] connectionData, Parameter[] paramlist, CancellationToken token) /// - /// 4 + /// 3 /// The UUID of destination TA /// The token for task manipulation /// Returns Task executing session open in backgroung @@ -519,7 +518,6 @@ namespace Tizen.Security.TEEC /// Thrown when application does not have privilege to access this method. /// The required feature is not supported. /// The operation is invalid. - /// One of arguments is wrong public async Task OpenSessionAsync(Guid destination, CancellationToken token = default(CancellationToken)) { Task task = Task.Factory.StartNew(() => @@ -534,7 +532,7 @@ namespace Tizen.Security.TEEC /// the scope of the specified Context, in accordance with the parameters. /// The input MUST point to the shared memory region to register /// - /// 4 + /// 3 /// The address of shared memory /// The size of shared memory /// The flags describing access modes (Input and/or Output) @@ -561,7 +559,7 @@ namespace Tizen.Security.TEEC /// This function allocates a new block of memory as a block of Shared Memory within the scope of the /// specified Context, in accordance with the parameters. /// - /// 4 + /// 3 /// The size of shared memory /// The flags describing access modes (Input and/or Output) /// Returns SharedMemory handler @@ -591,7 +589,7 @@ namespace Tizen.Security.TEEC /// underlying memory from the TEE, but the memory region will stay available to the Client Application for /// other purposes as the memory is owned by it. /// - /// 4 + /// 3 /// The shared memory object returned by RegisterSharedMemory or AllocateSharedMemory /// http://tizen.org/privilege/tee.client /// partner