On Tue, Jan 04, 2022 at 07:20:47PM +0100, Claudio Jeker wrote:
> On Tue, Jan 04, 2022 at 04:57:23PM +0100, Theo Buehler wrote:
> > On Tue, Jan 04, 2022 at 04:15:56PM +0100, Claudio Jeker wrote:
> > > This is another diff on the way to having a validated repo.
> > > Pass the filename of the entity which was parsed back to the parent.
> > > With this we can move the filepath_add() call from entity_write_req()
> > > to entity_process(). As a side-effect the "Already visited" check is moved
> > > after parsing so a file may be reparsed before being ignored. I doubt this
> > > causes an issue.
> > > 
> > > On top of this change how entp->file is passed to the individual parser
> > > functions. Just pass the filename to those functions. Only exception for
> > > now is proc_parser_root_cert() since it accesses more of the entp.
> > > 
> > > Again this is done to make it possible to have the parser decide which
> > > path to use for accessing a file. For now this is just shuffling code but
> > > once the code has two places to look for a file this will be all needed.
> > 
> > ok tb
> > 
> > This will need a little bit of work on top of the verify_cb() commit.
> > Something like
> > 
> > sed -i '/set_app_data/s/entp->/(char *)/' parser.c
> > 
> > should do it (or whichever way you want to deal with the const issue
> > arising from the fact X509_STORE_CTX_set_app_data() taking a non-const
> > void * as a second argument).
> 
> I actually removed the const from the various function prototypes. While
> nice it is not needed there and I prefer that over extra casts because of
> const.

Agreed.

ok tb

Reply via email to