package com.sunyard.chsm.sdf.model;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

/**
 * @author liulu
 * @version V1.0
 * @since 2022/11/11
 */
@Data
@NoArgsConstructor
@AllArgsConstructor
public class EccSignature {

    // 签名的 r 部分
    private byte[] r;

    // 签名的 s 部分
    private byte[] s;

    public byte[] getRawSignBytes() {
        byte[] signData = new byte[r.length + s.length];
        System.arraycopy(r, 0, signData, 0, r.length);
        System.arraycopy(s, 0, signData, r.length, s.length);
        return signData;
    }


}
